sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: pytorch
Issue: Inconsistent usage of `attn_mask` and `is_causal` arguments
Labels: module: nn,triaged

### 📚 The doc issue

In the docs describing `F.scaled_dot_product_attention` we can read:

> is_causal (bool) – If true, assumes causal attention masking and errors if both attn_mask and is_causal are set.

So if `is_causal=True` then we also need `attn_mask=None` or it will throw exception. Got it.

But let's see `nn.MultiheadAttention.forward` method.

> is_causal (bool) – If specified, applies a causal mask as attention mask. Default: False. Warning: is_causal provides a hint that attn_mask is the causal mask. Providing incorrect hints can result in incorrect execution, including forward and backward compatibility.

Hard to understand what does it exactly mean, so lets try it. If we run it with `is_causal=True` and `attn_mask=None` it will throw exception:

RuntimeError: Need attn_mask if specifying the is_causal hint. You may use the Transformer module method `generate_square_subsequent_mask` to create this mask.

So now is the opposite and `is_causal=True` needs `attn_mask` to be not `None`.

So what exactly this two args represent? Since multi-head attention and scaled dot product are two concepts so closely related to each other, shouldn't it be more consistent?

### Suggest a potential alternative/fix

_No response_

cc @albanD @mruberry @jbschlosser @walterddr @mikaylagawarecki @bhosmer @cpuhrsch @erichan1 @drisspg
Repository: vscode
Issue: Syntax highlighting error in PHP function parameter when string literal contains block comment
Labels: languages-basic

<!-- ⚠️⚠️ 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?: Yes

<!-- 🪓 If you answered No above, use 'Help: Start Extension Bisect' from Command Palette to try to identify the cause. -->
<!-- 📣 Issues caused by an extension need to be reported directly to the extension publisher. The 'Help > Report Issue' dialog can assist with this. -->
- VS Code Version: 
- OS Version: 
- Version: 1.86.0
Commit: 05047486b6df5eb8d44b2ecd70ea3bdf775fd937
Date: 2024-01-31T10:29:11.933Z
Electron: 27.2.3
ElectronBuildId: 26495564
Chromium: 118.0.5993.159
Node.js: 18.17.1
V8: 11.8.172.18-electron.0
OS: Darwin arm64 23.3.0

Steps to Reproduce:

1. Write valid PHP code with a string literal that contains `/*`.
2. Observe that the rest of the code highlighting will be broken until a new string literal containing `*/` is introduced. See the example below:

```php
<?php

declare(strict_types=1);

$jsCode = '/* <![CDATA[ */ var data = {"a": 1, "b": 2} /* ]]> */;';
$jsCode = str_replace("/* <![CDATA[ */", '', $jsCode);
$jsCode = str_replace("/* ]]> */", '', $jsCode);
var_dump($jsCode);
```
Refer to line 6 and 7 for the error:

![php-code](https://github.com/microsoft/vscode/assets/45931795/e80a5873-18ef-4a0b-8fe3-e2d70f30a96e)
Repository: ant-design
Issue: 开启虚拟列表的select在滚动条达到底部时，继续滚动的行为会影响到select内部的行为
Labels: Inactive,improvement

![动画](https://github.com/ant-design/ant-design/assets/59015993/924e2d2d-70e7-4d6a-8121-b176814e4f20)
### Reproduction link

[https://ant.design/components/select-cn](https://ant.design/components/select-cn)

### Steps to reproduce

复现条件：
1、select下拉列表有滚动条
2、外部列表课滚动

复现步骤：
1、将select滚动条置于底部，这时等待50ms的lock，后续可继续滚动滚动条，这时就是滚动外部的滚动条了，
2、滚动到鼠标离开下拉框后，立即反向滚动，select内部的滚动条也会向上滚动，即使鼠标没在下拉框内部

### What is expected?

到鼠标离开下拉框后，除非鼠标重新回到下拉框内部，否则不应该触发内部的scroll事件

### What is actually happening?

目前是会触发上述行为的

| Environment | Info |
| --- | --- |
| antd | 5.13.3 |
| React | 17.* |
| System | win 10 |
| Browser | chrome 120.0.6099.130 |

---
在业务中，对全局的scroll事件做了监听，只要发生滚动，会模拟点击行为来关闭select下拉框，由于上述问题，反向滚动后，关闭下拉框时的位置和虚拟列表的数据不符合，发生了错位，导致有部分白屏产生

https://github.com/react-component/select/issues/1023
<!-- generated by ant-design-issue-helper. DO NOT REMOVE -->
Repository: ant-design
Issue: 新增hook，Form.List.usePrefixName
Labels: Inactive,unconfirmed

### What problem does this feature solve?

场景：在某些复杂的大表单场景中，表单代码通常要拆分成好几个组件，在有多个Form.List嵌套的后代组件中，想要拿到完整的namePath并不容易，需要层层传递props；
目的：希望可以在所有的后代元素中，使用hook就可以拿到prefixName；

### What does the proposed API look like?

`type Form.List.usePrefixName = (): (string | number)[] | undefined`

<!-- generated by ant-design-issue-helper. DO NOT REMOVE -->
Repository: godot
Issue: Opaque tiles in tilemaps stop rendering tiles behind
Labels: enhancement,discussion,topic:2d

### Tested versions

Currently happens 4.2.1 but has been present in 4.1.x and 4.0.x.

### System information

Godot v4.2.1.stable - Arch Linux #1 SMP PREEMPT_DYNAMIC Thu, 21 Dec 2023 19:01:01 +0000 - Tty - Vulkan (Forward+) - dedicated AMD Radeon RX 580 Series () - AMD Ryzen 7 3800X 8-Core Processor (16 Threads)

### Issue description

Placing opaque tiles on a tilemap on an upper layer prevents tiles behind from rendering.  This wouldn't normally be a problem but if a pixel shader is used that would allow the background to show through, this doesn't work, as what's behind the whole tilemap shows through instead.

### Steps to reproduce

Create a tilemap with 2 layers and some tileset.  Add a shader material to one of the tiles and have it somehow refer to the Screen Texture2D.  Put some tile on the first layer, then the shaded tile on the second layer over the tile on the first layer, and the tile on the first layer will disappear.  It may take a moment or require hovering over it or having the screen redraw or something I dunno what exactly triggers it, but once it disappears it's just gone for good until the tile in front is deleted.  Also, I've had it not happen but I think this was because it was over another tile that had transparent pixels, or maybe because it also had a shader material?  That's the only difference I could tell.
I was able to reproduce it by creating a second tileset with 2 layers and doing the same again.  It seems very random.

### Minimal reproduction project (MRP)

[Minimal Tilemap Bug Project.zip](https://github.com/godotengine/godot/files/14136438/Minimal.Tilemap.Bug.Project.zip)
Repository: vscode
Issue: Multi diff editor: provide right context for current resource
Labels: feature-request,multi-diff-editor

For each action in multi diff editor (resource menu, lines) the context should be correctly set to current resource. Right now I see this context:
```
    "groupEditorsCount": 17,
    "resource": "multi-diff-editor:1780.9827875781254534",
    "resourceScheme": "multi-diff-editor",
    "resourceFilename": "1780.9827875781254534",
    "resourceDirname": ".",
    "resourcePath": "1780.9827875781254534",
    "resourceLangId": "unknown",
    "resourceExtname": ".9827875781254534",
    "resourceSet": true,
```

instead of **resource** (and accompanying fields) being set to current resource, i.e one of URIs that was passed to `vscode.changes` command.

This makes adding new filesystem-specific menu items (with newly added `multiDiffEditor/resource/title` extension point) impossible.
Repository: vscode
Issue: Multi diff editor: implement `focus` and `hasFocus`
Labels: bug,verification-found,diff-editor,workbench-editors

Does this issue occur when all extensions are disabled?: Yes
- VS Code Version: 1.86.0
- OS Version: MacOs

Steps to reproduce:
1. Split window to 2 tab groups
2. Open normal editor in 1st tab group.
3. Open multi diff editor in 2nd tab group.
4. Focus normal editor.
5. Run `View: Focus Next Editor Group`

Expected: multi diff editor is focused.
Current: normal editor stays focused.
Repository: next.js
Issue: Error in importing images: Image import "<Image path>" is not a valid image file. The image may be corrupted or an unsupported format.
Labels: bug,Image (next/image)

### Link to the code that reproduces this issue
https://codesandbox.io/p/live/9f5ef667-da40-4e4c-a86c-71441bbcd52b

### To Reproduce

Add png image in public folder and try to import it in app/page.js. I could not completely reproduce it in codesandbox. But the issue is with accessing png images.

### Current vs. Expected behavior

current behavior: throwing error saying, "The image may be corrupted or an unsupported format."

### Provide environment information

```bash
Node Js version - 20.6.1
Next Version - 14.1.0
```


### Which area(s) are affected? (Select all that apply)

Image optimization (next/image, next/legacy/image)

### Which stage(s) are affected? (Select all that apply)

next dev (local)

### Additional context

I am using chrome and got this error in setting up new next js project.
Repository: PowerToys
Issue: keybord managment programming with shift doesn't works
Labels: Issue-Bug,Product-Keyboard Shortcut Manager,Needs-Triage,Needs-Team-Response

### Microsoft PowerToys version

0.78

### Installation method

PowerToys auto-update

### Running as admin

Yes

### Area(s) with issue?

Keyboard Manager

### Steps to reproduce

i remapping al shift + number and it's work but when i map shift + the original à and ù doesn't work

### ✔️ Expected Behavior

if i tap shift + à or shift + ù sent back “ or ? 

### ❌ Actual Behavior

it sent back what i mapped without the shift

### Other Software

_No response_
Repository: storybook
Issue: Portable stories - Create `compose` functions for Svelte
Labels: svelte,portable stories

Currently there are testing APIs (`composeStory`, `composeStories`, `setProjectAnnotations`) for React and Vue3, but not for Svelte.

Here's a reference on how it's done for Vue3:
https://github.com/storybookjs/storybook/blob/4a6df46b1ab32fa9f8c2b82703a235b158460b14/code/renderers/vue3/src/testing-api.ts

And React:
https://github.com/storybookjs/storybook/blob/645439adfbb543b5dadb28a471f2da7166c1c6b1/code/renderers/react/src/testing-api.ts
Repository: TypeScript
Issue: When generating declaration file from a JavaScript file with JSDoc, description of named parameters should be copied to description of the properties in the generated object type
Labels: Suggestion,Awaiting More Feedback

### 🔍 Search Terms

* copy description from jsdoc to properties
* named parameter description 

### ✅ Viability Checklist

- [X] This wouldn't be a breaking change in existing TypeScript/JavaScript code
- [X] This wouldn't change the runtime behavior of existing JavaScript code
- [X] This could be implemented without emitting different JS based on the types of the expressions
- [X] This isn't a runtime feature (e.g. library functionality, non-ECMAScript syntax with JavaScript output, new syntax sugar for JS, etc.)
- [X] This isn't a request to add a new utility type: https://github.com/microsoft/TypeScript/wiki/No-New-Utility-Types
- [X] This feature would agree with the rest of our Design Goals: https://github.com/Microsoft/TypeScript/wiki/TypeScript-Design-Goals

### ⭐ Suggestion

Currently, the description that follows a `@param options.field Description of field` does not copy `Description of field` to the corresponding property in the generated object type. But TypeScript should've done that.

Related: https://github.com/microsoft/TypeScript/issues/57328

### 📃 Motivating Example

JavaScript file:

```javascript
/**
 * Do something
 * @param {Object} options Description of options
 * @param {String} options.foo Description of foo
 * @param {Number} options.bar Description of bar
 */
export function doSomething(options) {
  console.log(options)
}
```

tsconfig:

```json
{
  "compilerOptions": {
    "allowJs": true,
    "checkJs": true,
    "declaration": true,
    "emitDeclarationOnly": true,
    "strict": true,
    "strictNullChecks": true,
    "module": "ES2022",
    "target": "ES2022"
  }
}
```

**Expected behavior:**

```typescript
/**
 * Do something
 * @param {Object} options Description of options
 * @param {String} options.foo Description of foo
 * @param {Number} options.bar Description of bar
 */
export function doSomething(options: {
    /** Description of foo **/
    foo: string;
    /** Description of bar **/
    bar: number;
}): void;
```

**Actual behavior:**

```typescript
/**
 * Do something
 * @param {Object} options Description of options
 * @param {String} options.foo Description of foo
 * @param {Number} options.bar Description of bar
 */
export function doSomething(options: {
    foo: string;
    bar: number;
}): void;
```



### 💻 Use Cases

1. What do you want to use this for? Generate TypeScript declarations with working intellisense
2. What shortcomings exist with current approaches? Intellisense ignores descriptions of named parameter
3. What workarounds are you using in the meantime? None
Repository: storybook
Issue: Portable stories - Create `compose` functions for SvelteKit
Labels: sveltekit,portable stories

Currently there are testing APIs (`composeStory`, `composeStories`, `setProjectAnnotations`) for React and Vue3, but not for SvelteKit.

Here's a reference on how it's done for Vue3:
https://github.com/storybookjs/storybook/blob/4a6df46b1ab32fa9f8c2b82703a235b158460b14/code/renderers/vue3/src/testing-api.ts

And React:
https://github.com/storybookjs/storybook/blob/645439adfbb543b5dadb28a471f2da7166c1c6b1/code/renderers/react/src/testing-api.ts
Repository: vscode
Issue: Unable to load vscode-remote://codespaces%<REDACTED: user-file-path>: Request through port forwarding failed.
Labels: error-telemetry

```javascript
Error: Unable to load vscode-remote://codespaces%<REDACTED: user-file-path>: Request through port forwarding failed.
at le.N (https:/<REDACTED: user-file-path>:2056:24557)
at async Promise.all (index 0)
```
[Go to Errors Site](https://errors.code.visualstudio.com/card?ch=8b3775030ed1a69b13e4f4c628c612102e30a681&bH=b2429d11-6dd8-1584-afa6-b789c386fcc6)
Repository: excalidraw
Issue: Rotated element offset is off in SVG export
Labels: bug

The effect gets stronger with size - i.e. large objects have larger offsets.
This only effects rotated elements. The linear element in the example is rotated by ~180 deg.

Here's my demo drawing: https://excalidraw.com/#json=rzhKCPyIJV9hXNjvQiULT,Y66njzhDCno-2CXVO-trzQ

This is how it looks on screen:
![image](https://github.com/excalidraw/excalidraw/assets/14358394/251c538f-930f-4272-8186-6cc8fdfc2460)

And this is how the svg export looks like:
![image](https://github.com/excalidraw/excalidraw/assets/14358394/e1453b56-f8ce-4aea-aa03-8ae63b89a728)
Repository: kubernetes
Issue: PostStartHook "scheduling/bootstrap-system-priority-classes" failed: unable to add default system priority classes: timed out waiting for the condition`
Labels: kind/bug,sig/api-machinery,triage/accepted

### What happened?

PostStartHook failed
`E0122 06:54:22.018964      10 writers.go:131] apiserver was unable to write a fallback JSON response: http: Handler timeout
W0122 06:54:22.457480      10 storage_scheduling.go:106] unable to get PriorityClass system-node-critical: Get "https://*.*.*.*:8443/apis/scheduling.k8s.io/v1/priorityclasses/system-node-critical": net/http: TLS handshake timeout. Retrying...
F0122 06:54:22.457615      10 hooks.go:203] PostStartHook "scheduling/bootstrap-system-priority-classes" failed: unable to add default system priority classes: timed out waiting for the condition`


### What did you expect to happen?

PostStartHook not failed

### How can we reproduce it (as minimally and precisely as possible)?

1.Apiserver is deployed using static Pods
2.The other service accesses Apiserver through Apiserver's serviceip
3.Limit the CPU of the Apiserver as much as possible
4.Simulate as many requests as possible to overload Apiserver's CPU

### Anything else we need to know?

All Poststarthooks are called asynchronously by the go coroutine
Through reading the code, I found that the service and endpoint tuning process of Apiserver is also carried out by goroutine(pkg/controlplane/instance.go:508:)
his leads to the problem of executing other poststarthooks after the Apiserver has been placed on the endpoint back end to provide service. Since Apiserver has already provided services at this time, if there is a high concurrency and many requests, the load of Apiserver will be too high, and eventually the PostStartHook request will time out, and Apiserver will eventually kill itself



### Kubernetes version

[root@master1 ~]# kubectl version
Client Version: v1.28.1
Kustomize Version: v5.0.4-0.20230601165947-6ce0bf390ce3
Server Version: v1.28.1


### Cloud provider

nil


### OS version

nil


### Install tools

look:How can we reproduce it (as minimally and precisely as possible)?


### Container runtime (CRI) and version (if applicable)

containerd


### Related plugins (CNI, CSI, ...) and versions (if applicable)

CNI:calico
Repository: vscode
Issue: SCM - contextKeyCollection property API proposal
Labels: feature-request,scm,api-proposal

We are exploring new extension api to set context keys scoped to a particular SCM provider.

```ts

export interface ContextKeyCollection {
	get(key: string): string | number | boolean | undefined;
	set(key: string, value: string | number | boolean | undefined): void;
	delete(key: string): void;
	clear(): void;
}

export interface SourceControl {	
	readonly contextKeyCollection: ContextKeyCollection;
}
```
Repository: angular
Issue: Validators do not always work the expected way
Labels: area: forms

### Which @angular/* package(s) are the source of the bug?

forms

### Is this a regression?

No

### Description

We've come across to what I think is a bug in form validation in reactive forms. Stackblitz is kind of self-explanatory, but to sum it up, when creating FormControl (that is not visible right away on the view), validation works differently depending on how validators are passed onto the control (simple validator vs array of validators).

If you open the stackblitz, and right away click on the buttons you'll see that one of the forms shows an alert and the other doesn't. The only difference between these two is the validatorOrOpts param used to create the controls.

### Please provide a link to a minimal reproduction of the bug

https://stackblitz.com/edit/stackblitz-starters-378jka?file=src%2Fmain.ts

### Please provide the exception or error you saw

```true
Both forms should either be valid or invalid (based on the expected behaviour from the Angular team) instead of varying based on how the ValidatorFn are passed.
```


### Please provide the environment you discovered this bug in (run `ng version`)

```true
Angular CLI: 17.1.2
Node: 18.18.0
Package Manager: npm 10.2.3
OS: linux x64

Angular: 17.1.2
... animations, cli, common, compiler, compiler-cli, core, forms
... platform-browser, platform-browser-dynamic, router

Package                         Version
---------------------------------------------------------
@angular-devkit/architect       0.1701.2
@angular-devkit/build-angular   17.1.2
@angular-devkit/core            17.1.2
@angular-devkit/schematics      17.1.2
@schematics/angular             17.1.2
rxjs                            7.8.1
typescript                      5.3.3
zone.js                         0.14.3
```


### Anything else?

After further testing looks like changing the validator's return from
```
  static test(control: AbstractControl): ValidationErrors | null {
    return {
      ...Validators.maxLength(10)(control),
    };
  }
```
to
```
  static test(control: AbstractControl): ValidationErrors | null {
    return Validators.maxLength(10)(control);
  }
```

solves the issue, but looks like a random difference in validation :/

In our case we're using the first to return all the errors in one (as we have some complex validators that might need of all the errors to properly build feedback for the user).
Repository: node
Issue: Flaky: test-http-upload-timeout
Labels: s390,flaky-test

### Test

test-http-upload-timeout

### Platform

Linux s390x

### Console output

```console
Error Message
fail (1)
Stacktrace
---
duration_ms: 1576.312
exitcode: 1
severity: fail
...
```


### Build links

- https://ci.nodejs.org/job/node-test-commit-linuxone/nodes=rhel8-s390x/42001

### Additional information

_No response_
Repository: pytorch
Issue: dynamo graph breaks on DTensor.to_local(grad_placements=grad_placements)
Labels: oncall: distributed,triaged,oncall: pt2,module: dynamo,dynamo-tensor-subclasses,pt2d-triage-nov2024

Dynamo graph breaks when there are actual placements kwargs, because placements can't be proxied into the dynamo graph
```
+    def test_dynamo_to_local_kwargs(self):
+        mesh = DeviceMesh(self.device_type, torch.arange(self.world_size))
+
+        @torch.compile(backend="eager", fullgraph=True)
+        def fn(x):
+            return dt.to_local(grad_placements=[Shard(0)]) + 2
+
+        x = torch.ones(4)
+        dt = DTensor.from_local(x, mesh, [Replicate()], run_check=False)
+        # no graph breaks
+        out = fn(dt)
```

cc @XilunWu @H-Huang @awgu @kwen2501 @wanchaol @fegin @fduwjj @wz337 @wconstab @d4l3k @c-p-i-o @ezyang @chauhang @penguinwu @voznesenskym @EikanWang @jgong5 @Guobing-Chen @XiaobingSuper @zhuhaozhe @blzheng @wenzhe-nrv @jiayisunx @chenyang78 @kadeng @amjames @rec @anijain2305 @msaroufim @zou3519 @aakhundov
Repository: PowerToys
Issue: NinjaTrader 8 not working with FancyZones
Labels: Issue-Bug,Needs-Triage,Needs-Team-Response

### Microsoft PowerToys version

0.78.0

### Installation method

GitHub

### Running as admin

Yes

### Area(s) with issue?

FancyZones

### Steps to reproduce

Im trying to snap Ninja Trader 8 windows and can't snap to the zones and these doesn't even show up. I could snap other programs but couldn't with NT8 (windows snap works fine)

### ✔️ Expected Behavior

snap NT8 windows to the zones

### ❌ Actual Behavior

NT8 windows won't snap to the zones and these don't light up

### Other Software

_No response_