sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: kubernetes
Issue: Document and implement proper service-endpoint lifecycle (Gracefully draining Services/Endpoints)
Labels: kind/bug,sig/network,kind/cleanup,priority/important-longterm,lifecycle/frozen,triage/accepted

### What happened?

Currently when services or endpoints are deleted we remove the conntrack entries for UDP & SCTP services:
https://github.com/kubernetes/kubernetes/blob/88f97283393715c7fa870dd90be0fd0d0faad6bd/pkg/proxy/iptables/proxier.go#L736
https://github.com/kubernetes/kubernetes/blob/c5fbcd735d67a7cc209301dc690579fb0816e2ab/pkg/util/conntrack/conntrack.go#L132

This causes ABORT to never happen and hence no graceful termination. At the same time if we don't clean the conntrack entries and if users are re-using the src ports, then we'll have stale entries preventing the new entries from being created; example: https://github.com/kubernetes/kubernetes/issues/101607. SCTP is more like TCP and is stateful; so the expectation is for them to behave similarly; but today we are treating it like UDP?

So there are two ways forward:

1. When services are deleted we cleanup the entries and continue not allowing ABORTS or graceful terminations for already ESTABLISHED connections like we are doing now in kube-proxy. See https://github.com/kubernetes/kubernetes/issues/101607#issuecomment-855461836
2. We don't touch conntrack for connection oriented protocols and let the protocol take its natural course through the various states, maybe this will motivate people to use random source ports. This means even if services go away, ESTABLISHED connections continue to work until they get ABORTED and conntrack cleanup will happen naturally.

/cc @dcbw @danwinship @aojea @trozet

### What did you expect to happen?

The exact expectations or "right way of doing things" around this problem need to be discussed/figured out. Note that this item was brought up in the sig-network meeting on the 3rd of March 2022. We had a few ideas like:

Quoting @dcbw's meeting notes:
> deleting a Service object meant that the service was no longer guaranteed to work.
> Instead, to drain a service, the label gets changed and thus no endpoints, and new connections get rejected.
> But the Service sticks around and existing connections work until the backend pods are deleted, or the Service is finally deleted.

Since we didn't have a clear consensus, opening this issue where we can clearly document the agreed way forward. 

### How can we reproduce it (as minimally and precisely as possible)?

Same steps as here: https://github.com/kubernetes/kubernetes/issues/70020
The WORKAROUND2 mentioned in the above issue ^ was implemeted through https://github.com/kubernetes/kubernetes/pull/74073; but SCTP is stateful like TCP and since we nuke the entries, the SHUTDOWN/ABORT will never happen? We are not gracefully terminating.
Repository: go
Issue: runtime: timeout in TestNoShrinkStackWhileParking on openbsd
Labels: OS-OpenBSD,NeedsInvestigation

`greplogs --dashboard -md -l -e 'TestNoShrinkStackWhileParking'`

[2022-01-06T19:21:12-ed84a83/openbsd-386-70-n1](https://build.golang.org/log/e3462826f22cfcbde9d4747b490490703c8f95c5)    
[2021-11-27T23:25:39-7e1260f/openbsd-amd64-70-n1](https://build.golang.org/log/e958df750eb633f2eb7d5a7b803dbc180d5fbc9e)  
[2021-11-08T21:45:43-cc49178/openbsd-386-68](https://build.golang.org/log/3e77d7e74aa011000629901d020ebe2fb6424a9d)

cc @golang/runtime @bcmills
Repository: TypeScript
Issue: Conflict between imported namespace and global type in generated declaration file
Labels: Bug,Help Wanted,Domain: Declaration Emit

# Bug Report

<!--
  Please fill in each section completely. Thank you!
-->

### 🔎 Search Terms

<!--
  What search terms did you use when trying to find an existing bug report?
  List them here so people in the future can find this one more easily.
-->

namespace import declaration conflict global types date-fns

### 🕗 Version & Regression Information

<!-- When did you start seeing this bug occur?

"Bugs" that have existed in TS for a long time are very likely to be FAQs; refer to
  https://github.com/Microsoft/TypeScript/wiki/FAQ#common-bugs-that-arent-bugs

If possible, please try testing the nightly version of TS to see if it's already been fixed.
For npm: `typescript@next`
This is also the 'Nightly' version in the playground: http://www.typescriptlang.org/play/?ts=Nightly

Note: The TypeScript Playground can be used to try older versions of TypeScript.

Please keep and fill in the line that best applies:
-->
- This is the behavior in every version I tried, and I reviewed the FAQ for entries about declaration files

### ⏯ Playground Link

<!--
  A link to a TypeScript Playground "Share" link which shows this behavior

  The TypeScript Workbench can be used for more complex setups, try
  https://www.typescriptlang.org/dev/bug-workbench/

  As a last resort, you can link to a repo, but these will be slower for us to investigate.
-->
[Playground link with relevant code](https://www.typescriptlang.org/play?#code/PTAEFkE9QYwewCYFNQHM5IM6gBZIE5JA)

### 💻 Code

`locale.ts`:

```ts
export type T = {};

```

`types.d.ts`:

```ts
type Locale = {
  code?: string
}
declare module 'date-fns/locale' {
  const es: Locale
  namespace es {}
}
```

`main.ts`:

```ts
import { es } from "date-fns/locale";
import * as Locale from "./locale";

export const f = (locale: Locale.T) => es;

```

Run `tsc` with `"declaration": true`.

### 🙁 Actual behavior

`tsc` runs with no errors, but the following `main.d.ts` file is generated:

```ts
import * as Locale from "./locale";
export declare const f: (locale: Locale.T) => Locale;
```

When we try to use this `.d.ts` file in another TS project we get this error:

```
Cannot use namespace 'Locale' as a type
```

<img width="657" alt="image" src="https://user-images.githubusercontent.com/921609/156829869-31ef27f7-99e3-48a8-ae33-4b7e4416c81b.png">


### 🙂 Expected behavior

No conflict. Perhaps the namespace import should be renamed in the `.d.ts` file.
Repository: PowerToys
Issue: Adjust Image Resizer string to remove translation clarity issue
Labels: Area-Localization,Cost-Small,Issue-Translation

### Microsoft PowerToys version

0.56.1

### Utility with translation issue

Image Resizer

### 🌐 Language affected

German

### ❌ Actual phrase(s)

![image](https://user-images.githubusercontent.com/100710031/156835967-6fca457f-1a8f-48da-b55e-a2ca5c1d85b6.png)

"Passt in [resolution] pixel"

### ✔️ Expected phrase(s)

Only the resolution.

Format: "[width] x [height] [unit]"
e. g.: 1920 x 1080 Pixel (no the capital letter at the beginning of the word "Pixel" is not a spelling mistake)

**CRUTKAS possible solution:** Mode - Width x Height unit

### ℹ Why is the current translation wrong

Sounds wrong in my ears. It sounds better when you simply put the new resolution of the new picture there
Repository: PowerToys
Issue: Review & clean up GlobalSuppression.cs
Labels: Area-Quality,Area-Build

Review & clean up `GlobalSuppression.cs`. Create dedicated issues for warnings which should be unsuppressed.

---
for stuff supressed, lets create dedicated issues to unsupress

_Originally posted by @crutkas in https://github.com/microsoft/PowerToys/issues/16543#issuecomment-1051133954_
Repository: angular
Issue: DomSanitizer should keep style attributes in HTML but sanitize them if needed
Labels: security,area: core,core: sanitization,P3

### Which @angular/* package(s) are the source of the bug?

platform-browser

### Is this a regression?

No

### Description

DOM sanitizer removes style attribute from all elements.
Expected behavior
DOM santitizer keeps the style attribute on elements, but sanitizes the actual style value if needed, so something innocuous like style="text-align: center" isn't lost.
So when I use sanitizer.sanitize(SecurityContext.HTML, someHtmlContainedString) I expect to receive html with attributes like id, styles, class if the original string contained them. But if it contaied tags like <script> <a href="javascript:alert('hack')"></a> - the javascript / script tags should be sanitized. 

This issue was mistakely closed in https://github.com/angular/angular/issues/19645 with explanation that the latest version of angular should fix it, but it don't.
So this one is just a reopen.



### Please provide a link to a minimal reproduction of the bug

http://plnkr.co/edit/AjJMr2pDz8IxvucnpTbC?p=preview

### Please provide the exception or error you saw

```true
I receive incorrect html with sanitized style attr.
```


### Please provide the environment you discovered this bug in (run `ng version`)

```true
Angular CLI: 13.2.5
Node: 16.13.0      
Package Manager: npm 7.24.2
OS: win32 x64

Angular: 13.2.5
... animations, cli, common, compiler, compiler-cli, core, forms
... platform-browser, platform-browser-dynamic, router

Package                         Version
---------------------------------------------------------
@angular-devkit/architect       0.1302.5
@angular-devkit/build-angular   13.2.5
@angular-devkit/core            13.2.5
@angular-devkit/schematics      13.2.5
@schematics/angular             13.2.5
rxjs                            7.5.4
typescript                      4.5.5
```


### Anything else?

My guessing is - the fix should be something like adding 'style' str into
const HTML_ATTRS = tagSet(
    'abbr,accesskey,align,alt,autoplay,axis,bgcolor,border,cellpadding,cellspacing,class,clear,color,cols,colspan,' +
    'compact,controls,coords,datetime,default,dir,download,face,headers,height,hidden,hreflang,hspace,' +   'ismap,itemscope,itemprop,kind,label,lang,language,loop,media,muted,nohref,nowrap,open,preload,rel,rev,role,rows,rowspan,rules,' +
    'scope,scrolling,shape,size,sizes,span,srclang,start,summary,tabindex,target,title,translate,type,usemap,' +
    'valign,value,vspace,width');
 or if it's still causes security vulnerability - add separate parse rules to sanitize style attrs.
   which is defined in https://github.com/angular/angular/blob/13.2.x/packages/core/src/sanitization/html_sanitizer.ts
If you might believe this is a correct behavior - please close with an explanation why.
Thanks!
Repository: svelte
Issue: `{@html ...}` tag is populated too late
Labels: compiler

### Describe the bug

Bear with me, this is a bit of an edge case.

If you have code like [this](https://svelte.dev/repl/d28fe0d4900d4a88b297c0f806d12067?version=3.46.4)...

```svelte
<script>
	let h = 0;

	const html = '<div style="height: 50vh"></div><div style="height: 100vh; background: salmon"><h3 id="foo">this should be at the top of the page</h3></div>';
</script>

<div bind:clientHeight={h} /><main>{@html html}</main>
```

it will compile with `hydratable: true` to this:

```js
		/* omitted */
		l(nodes) {
			div = claim_element(nodes, "DIV", {});
			children(div).forEach(detach);
			main = claim_element(nodes, "MAIN", {});
			var main_nodes = children(main);
			main_nodes.forEach(detach);
			this.h();
		},
		h() {
			add_render_callback(() => /*div_elementresize_handler*/ ctx[1].call(div));
		},
		m(target, anchor) {
			insert_hydration(target, div, anchor);
			div_resize_listener = add_resize_listener(div, /*div_elementresize_handler*/ ctx[1].bind(div));
			insert_hydration(target, main, anchor);
			main.innerHTML = html;
		},
		/* omitted */
```

Between `main_nodes.forEach(detach)` and `main.innerHTML = html`, the addition of the resize listener causes a reflow that, long story short, results in you losing your scroll position if you were previously scrolled to `#foo` and there's not much content on the page other than the contents of `{@html ...}`. This is currently visible on the SvelteKit docs: https://github.com/sveltejs/kit/issues/4216. (Only on Chrome, not Firefox.)

Removing the `bind:clientHeight` (or placing it below the `{@html ...}`) prevents the bug, as would using a `ResizeObserver` instead of the resize listener hack. But the biggest mystery is why we're waiting until the mount phase (`m`) to do `innerHTML = html` instead of the claim phase (`l`).

(Aside: it would be nice if there was a way to say 'you don't need to replace me, I promise my contents won't have changed since SSR' — `{@html:leavemealone post.html}` or whatever.)

### Reproduction

Open this [StackBlitz repro](https://stackblitz.com/edit/sveltejs-kit-template-default-pm2sdq?file=src%2Froutes%2Ffails.svelte&terminal=dev) and go to the standalone version: https://sveltejs-kit-template-default-pm2sdq--3000.local.webcontainer.io/

### Logs

_No response_

### System Info

```shell
System:
    OS: macOS 12.0.1
    CPU: (10) arm64 Apple M1 Max
    Memory: 90.30 MB / 32.00 GB
    Shell: 5.8 - /bin/zsh
  Binaries:
    Node: 16.13.1 - ~/.nvm/versions/node/v16.13.1/bin/node
    Yarn: 1.22.17 - ~/.nvm/versions/node/v16.13.1/bin/yarn
    npm: 8.1.2 - ~/.nvm/versions/node/v16.13.1/bin/npm
  Browsers:
    Chrome: 98.0.4758.109
    Firefox: 97.0.1
    Safari: 15.1
  npmPackages:
    svelte: ^3.43.0 => 3.44.2
```


### Severity

annoyance
Repository: flutter
Issue: Autofocus should delay request of focus until the material page is at the forefront
Labels: a: text input,framework,f: routes,f: focus,has reproducible steps,P2,found in release: 2.10,found in release: 2.11,team-framework,triaged-framework

If the navigator page stack contains more than one page, and a page that is not the one displayed requests focus through autofocus, that focus should be delayed until the page is put on the forefront and the focus should stay on the currently viewed page until then.


# Repro

Here is a repro repository https://github.com/cedvdb/flutter_repros/tree/autofocus (checkout the autofocus branch)

When you run the app and click on the button you'll see the focus disappear from the page that is shown because the underlying page hides the `TextFormField` for a second then respawns it.


Alternatively here is the repro code which needs the rxdart dep

```dart
import 'dart:async';

import 'package:flutter/material.dart';
import 'package:rxdart/rxdart.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(
        primarySwatch: Colors.blue,
      ),
      home: const MyHomePage(),
    );
  }
}

class MyHomePage extends StatefulWidget {
  const MyHomePage({Key? key}) : super(key: key);

  @override
  State<MyHomePage> createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {
  BehaviorSubject<int> streamController = BehaviorSubject.seeded(0);

  void _showOtherPage(BuildContext context) async {
    Navigator.of(context).push(
      MaterialPageRoute(
        builder: (ctx) => Scaffold(
          appBar: AppBar(),
          body: TextFormField(
            autofocus: true,
          ),
        ),
      ),
    );
    streamController.add(streamController.value + 1);
    await Future.delayed(const Duration(milliseconds: 800));
    streamController.add(streamController.value + 1);
  }

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: StreamBuilder(
        stream: streamController.stream,
        builder: (ctx, AsyncSnapshot<int> snap) {
          if (!snap.hasData) {
            return Container();
          }
          if (snap.data! % 2 == 0) {
            return Column(
              children: [
                TextFormField(autofocus: true),
                const SizedBox(height: 20),
                ElevatedButton(
                  onPressed: () => _showOtherPage(context),
                  child: const Text('show other page'),
                ),
              ],
            );
          }
          return Container();
        },
      ),
    );
  }
}

```


# workaround

replace page instead of having it in the stack
Repository: TypeScript
Issue: source.organizeImports causing extra blank line
Labels: Bug,Help Wanted,Domain: Refactorings


*TS Template added by @mjbvz*

**TypeScript Version**: 4.6.2

**Search Terms**
- organize imports
- source action 

---

Issue Type: <b>Bug</b>

source.organizeImports is adding an extra blank line at the end when the typescript file only has exports. If there are any other lines (e.g. code) after the exports, then the extra line does not get added.

VS Code version: Code 1.65.0 (b5205cc8eb4fbaa726835538cd82372cc0222d43, 2022-03-02T11:12:08.962Z)
OS version: Windows_NT x64 10.0.19044
Restricted Mode: No

Extensions: none
<!-- generated by issue reporter -->

In this project, I've created a new default Angular project and added an index.ts to show the issue.

![VSCode-OrganizeImports](https://user-images.githubusercontent.com/5217044/156839159-e81376a1-cc33-4eeb-a88a-5cd026865b91.gif)
Repository: TypeScript
Issue: Readonly semantic highlighting does not apply to Readonly<T> types
Labels: Bug

*TS Template added by @mjbvz*

**TypeScript Version**: 4.6.2

**Search Terms**
- semantic highlighting
- readonly
- token modifier 

---

<!-- ⚠️⚠️ Do Not Delete This! bug_report_template ⚠️⚠️ -->
<!-- Please read our Rules of Conduct: https://opensource.microsoft.com/codeofconduct/ -->
<!-- 🕮 Read our guide about submitting issues: https://github.com/microsoft/vscode/wiki/Submitting-Bugs-and-Suggestions -->
<!-- 🔎 Search existing issues to avoid creating duplicates. -->
<!-- 🧪 Test using the latest Insiders build to see if your issue has already been fixed: https://code.visualstudio.com/insiders/ -->
<!-- 💡 Instead of creating your report here, use 'Report Issue' from the 'Help' menu in VS Code to pre-fill useful information. -->
<!-- 🔧 Launch with `code --disable-extensions` to check. -->
Does this issue occur when all extensions are disabled?: N/A (this is about a bundled extension)

Version: 1.64.2
Commit: f80445acd5a3dadef24aa209168452a3d97cc326
Date: 2022-02-09T22:00:58.347Z
Electron: 13.5.2
Chromium: 91.0.4472.164
Node.js: 14.16.0
V8: 9.1.269.39-electron.0
OS: Darwin x64 19.6.0

Steps to Reproduce:

![Screen Shot 2022-02-25 at 11 51 55 AM](https://user-images.githubusercontent.com/8225332/155754897-892dd1bb-b8d8-4bd9-abe5-f1bb390f067d.png)

The above screenshot shows that even though `y.bar` is a `readonly` field (the compiler emits an error), it is not coloured as such.
Repository: flutter
Issue: Make Visual Studio CMake integration work
Labels: c: new feature,tool,platform-windows,a: desktop,P3,team-windows,triaged-windows

Currently the flow for native debugging of a Windows project is to run `flutter build windows` at least once, then open the `sln` file that's created in `build/windows/` and run from there. This is not at all intuitive, and has the downside that people may not realize that changes they make there aren't permanent.

Visual Studio also has the ability to directly open a directory with a CMake project, but currently it doesn't work (largely because when I was doing the build conversion to CMake, the VS/CMake integration was completely broken on my machine, and it was never enough of a priority to come back to.) It default to the ninja generator, which our Windows CMake files don't currently support (they are written exclusively for multi-config generators), and it looks like it also defaults to `clang-cl`. It looks like we should be able to add [a configuration file](https://docs.microsoft.com/en-us/cpp/build/cmake-presets-vs?view=msvc-170) to the template that would set:
- the generator (we wouldn't be able to do this dynamically, but we could just set it to VS 2022 and people could change it if they needed to)
- the compiler
- ideally the build output folder so it's using the same destination we are
- anything else that needs adjusting from defaults

We should see if just doing that makes it possible for someone to get a good VS experience without having to ever deal with the generated solution file. (One thing we'll need to look at is how it handles the `install` step, since we've co-opted that to make the self-contained bundle that's needed to run.) If so, we should add that to the template.
Repository: three.js
Issue: Consider repair or delete the sharedPhysics Attribute in MMDAnimationHelper  
Labels: Bug,Addons

**Is your feature request related to a problem? Please describe.**

I noticed the sharedPhysics is in the MMDAnimationHelper can't work at all
![image](https://user-images.githubusercontent.com/72307252/156867866-273ab7f6-f93b-49ca-9558-3291374e91c8.png)
because it is  experimental and unless someone turned it on, it would always exist in the update function and do nothing.
![image](https://user-images.githubusercontent.com/72307252/156867922-b06232e1-7c54-4431-a001-09f453c36ab8.png)
Even worse,when I manually set the  sharedPhysics=true .it would calls the physics attribute of meshes,so it always return null because mesh does't had physics attribute.
![image](https://user-images.githubusercontent.com/72307252/156868026-f11fbb22-eff5-483c-88b3-5d9b6e473662.png)


**Describe the solution you'd like**

In fact, I also mention it in the threejs discourse:https://discourse.threejs.org/t/how-to-use-sharedphysics-in-mmdanimationhelper/35446/3, but unfortunately it seems  the author of MMDAnimationHelper @takahirox  doesn't watch the discourse, so I had to request here. Is the physics attribute need to be fixed or deprecated?


**Additional context**
English are not my native language, so if you feel that my description of the problem is not clear enough, please contact me
Repository: godot
Issue: A top corner pixel is missing in non-filled `CanvasItem.draw_rect()`
Labels: bug,topic:rendering,topic:2d

### Godot version

v4.0.alpha.custom_build [013efeef0]

### System information

Windows 10, Intel Core i5 7200U CPU, Vulkan

### Issue description

When using `CanvasItem.draw_rect()` with `fill = false` and `width = 1`, one of the top corner pixels are missing. From my observations, the top-left corner is missing when the pixel position is an integer and the top-right corner is missing when the pixel position has a decimal.

This also affects some areas of the editor, such as the 2D rectangle selection and the gradient editor:
![image](https://user-images.githubusercontent.com/67974470/156868084-017e2d52-2a9a-4737-b3b7-24e5b358b52e.png) ![image](https://user-images.githubusercontent.com/67974470/156868307-6f6174a3-27df-4211-b5c8-9ea1054b3a9e.png)


### Steps to reproduce

Each of these 3 options exhibits this bug:
a. Open the 2D editor and start a rectangle selection
b. Create a Gradient resource and add some points to the gradient editor
c. Attach a script to a CanvasItem-inherited node, and use `draw_rect()` with `fill = false` in the `_draw()` function.

### Minimal reproduction project

_No response_

### Possibly Related

https://github.com/godotengine/godot/pull/32657
https://github.com/godotengine/godot/issues/32279