sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: pytorch
Issue: Sparse tensor element-wise multiplication bug when broadcast needed
Labels: module: sparse,triaged

### 🐛 Describe the bug

Hi,
I noticed that when I try to multiply a dense tensor and a sparse tensor, if broadcast is required, it produces a wrong result. After reading a bit, it seems that sparse_tensor.expand() is not supported, which could be the reason behind this bug. 
Here you have a minimal example. You can notice that the number of non-zero items in r0 and r1 is the same, despite the broadcast. I assume that a NonImplementedException will be much appreciated for this issue.

```python
import torch

a = torch.randint(0,2, size=(32,512,512)).float()
b = torch.rand(*(6,512,512))

r0 = b.unsqueeze(1) * a.unsqueeze(0)

a_s = a.to_sparse_coo()

r1 = b.unsqueeze(1) * a_s.unsqueeze(0) #This does not work
# r1 = b.unsqueeze(1) * torch.stack([a_s for _ in range(b.shape[0])], dim=0) #This works

print(torch.isclose(r0, r1.to_dense()).all())
```

### Versions

Versions of relevant libraries:
[pip3] numpy==1.24.4
[pip3] pytorch-lightning==2.0.4
[pip3] torch==2.0.1
[pip3] torch-geometric==2.3.1
[pip3] torchaudio==2.0.2
[pip3] torchmetrics==1.0.0
[pip3] torchvision==0.15.2
[pip3] triton==2.0.0
[pip3] vit-pytorch==1.2.4
[conda] numpy                     1.24.4                   pypi_0    pypi
[conda] pytorch-lightning         2.0.4                    pypi_0    pypi
[conda] torch                     2.0.1                    pypi_0    pypi
[conda] torch-geometric           2.3.1                    pypi_0    pypi
[conda] torchaudio                2.0.2                    pypi_0    pypi
[conda] torchmetrics              1.0.0                    pypi_0    pypi
[conda] torchvision               0.15.2                   pypi_0    pypi
[conda] triton                    2.0.0                    pypi_0    pypi
[conda] vit-pytorch               1.2.4                    pypi_0    pypi


cc @alexsamardzic @nikitaved @pearu @cpuhrsch @amjames @bhosmer @jcaip
Repository: react
Issue: Bug: `undefined` within props is not faithfully deserialized from RSC payload
Labels: Type: Bug,Component: Flight

<!--
  Please provide a clear and concise description of what the bug is. Include
  screenshots if needed. Please test using the latest version of the relevant
  React packages to make sure your issue has not already been fixed.
-->

React version: `18.3.0-canary-0cdfef19b-20231211`

Related issues: https://github.com/facebook/react/issues/25687

## Steps To Reproduce

Object variant: 
1. Pass a `prop={{ x: undefined }}`  from a server component to a client component

Array variant: 
1. Pass a `prop={[0, undefined, 2]}`  from a server component to a client component


<!--
  Your bug will get fixed much faster if we can run your code and it doesn't
  have dependencies other than React. Issues without reproduction steps or
  code examples may be immediately closed as not actionable.
-->

Link to code example:

<!--
  Please provide a CodeSandbox (https://codesandbox.io/s/new), a link to a
  repository on GitHub, or provide a minimal code example that reproduces the
  problem. You may provide a screenshot of the application if you think it is
  relevant to your bug report. Here are some tips for providing a minimal
  example: https://stackoverflow.com/help/mcve.
-->

https://codesandbox.io/p/devbox/compassionate-benz-rj9dct

## The current behavior

Object properties that are `undefined` aren't present in the deserialized object, and arrays end up with empty slots instead:
```
{ x: undefined }     ->  {}
[ 0, undefined, 2 ]  ->  [ 0, <1 empty item>, 2 ]
```

## The expected behavior

If a property or array item is `undefined`, it should be deserialized as such. Object keys should remain present (with a value of `undefined`), and arrays shouldn't have empty slots.

Object properties aren't _that_ big of a deal, although a key being present (but undefined) may have some semantic meaning in the user's data model, so it's still not ideal. But empty slots behave in very surprising ways with e.g. `.map()`:

```js
> [0,,2].map((x) => x ?? 'default')
[ 0, <1 empty item>, 2 ]

> [0,undefined,2].map((x) => x ?? 'default')
[ 0, 'default', 2 ]
```

this is likely to bite anyone who maps over an array in order to display something, which is common in react.
Repository: godot
Issue: The red alignment lines when moving anchor points don't disappear after the anchor point is set
Labels: bug,topic:editor,topic:gui,topic:2d

### Tested versions

v4.2.1.stable.arch_linux

### System information

Godot v4.2.1.stable unknown - Manjaro Linux #1 SMP PREEMPT_DYNAMIC Wed Dec 20 07:15:58 UTC 2023 - X11 - Vulkan (Forward+) - dedicated NVIDIA GeForce GT 710 (nvidia; 470.223.02) - Intel(R) Core(TM) i5-3570 CPU @ 3.40GHz (4 Threads)

### Issue description

When the anchor point is moved via mouse there are red alignment lines that appear when the point is vertically or horizontally collinear with some other significant point/edge, i.e. container edge.
When I let go of LMB the anchor point is left on the wanted position, but the red lines are still there and don't disappear no matter what is selected.

### Steps to reproduce

- Make Control Node Scene
- Add any control node (I used Horizontal Box Container)
- Align any of its anchor points via mouse/cursor to an edge of some node (say Viewport/Parent node)
- The red guide/help alignment lines stay in place and don't disappear

### Minimal reproduction project (MRP)

N/A
Repository: PowerToys
Issue: FancyZones works well on multiple monitors with different DPI scaling
Labels: Issue-Docs,Needs-Triage

### Provide a description of requested docs changes

Hi,

The [online documentation](https://learn.microsoft.com/en-us/windows/powertoys/fancyzones#settings) as well as the tooltip within the FanxyZones settings state that if zones are allowed to span multiple monitors the DPI scaling of all monitors needs to be the same.

However, I use FancyZones on a setup with 3 Monitors where one has a different DPI scaling and it works perfectly fine.
The only issue is, that the graphical layout editor gets screwed up if the DPI scaling is not the same on all monitors. But if you calculate the zones' ratios manually and fill out the `%LocalAppData%\Microsoft\PowerToys\FancyZones\custom-layouts.json` file manually (doing this is mentioned by the docs), it works just fine. It even continues to work, when changing the DPI scaling of the monitors while still using the same layout config.

I suggest removing the strict "all monitors must have the same DPI scaling" wording and saying instead: "For the graphical zone editor to work, all monitors need to have the same DPI scaling, else manually populate the `custom-layouts.json` file."

Cheers!
Repository: PowerToys
Issue: Tool to make system-wide and/or app specific key-combo shortcuts esp allowing mouse right-click as a shortcut option.
Labels: Needs-Triage

### Description of the new feature / enhancement

As subject reads only with the added ability to have a key combo also simulate a right-click, in my case.   

For the right-click feature the tool should be content aware to know if I'm working in a text editor, file manager, or browser (such as with a selected link, for example). In the late 90's I owned a keyboard that had this feature and it's extremely useful.  More useful that I could have imagined.  So much so, in fact, that I still miss it going on two decades later. 

### Scenario when this would be used?

Described above

### Supporting information

Described above.
Repository: PowerToys
Issue: Option to limit output of remapped shortcuts to a desired amount
Labels: Idea-Enhancement,Product-Keyboard Shortcut Manager,Needs-Triage

### Description of the new feature / enhancement

That in the remap a key/remap a shortcut section, there could be an 'advanced' feature that can limit the output of the shortcut/text snippet to any desired number of outputs per second. E.g 2 outputs every 5 seconds. 

This would be so that if the remapped key/shortcut is accidently held down for too long, it won't activate too many times which could cause mayhem in certain scenarios like a remapped key to ctrl v being held down accidently. By default this would be disabled but would be customisable for every shortcut although there could be a 'global setting' for this too which applies it to all shortcuts by default. 

An example of how this could look has been included in the supporting information section.

### Scenario when this would be used?

When remapping something to the next track command, I could limit the output to 1 every 3 seconds so if I accidently held down the shortcut key to skip a track, it wouldn't skip more than one since it limits the output that I specified to the timeframe that I specified.

### Supporting information

Preview 1
![image](https://github.com/microsoft/PowerToys/assets/85837722/8ad66b3f-0192-4b32-a797-724a65e4ab84)
Preview 2
![image](https://github.com/microsoft/PowerToys/assets/85837722/9ce340d6-84a0-41c5-be5b-7df4e70af960)
Preview 3
![image](https://github.com/microsoft/PowerToys/assets/85837722/d02676c0-cd1e-4bf2-9d60-39c25d0f56f8)
Repository: PowerToys
Issue: Reorder Function Keys in Keyboard Manager
Labels: Issue-Bug,Needs-Triage

### Microsoft PowerToys version

0.76.2

### Installation method

PowerToys auto-update

### Running as admin

None

### Area(s) with issue?

Keyboard Manager

### Steps to reproduce

![image](https://github.com/microsoft/PowerToys/assets/85837722/a6ec2686-0df0-4c97-93ab-d31619810253)
The order of the Function keys [F1-F24] should be in order from 1-24 in ascending order rather than being organised by f1,f10,f11...

### ✔️ Expected Behavior

_No response_

### ❌ Actual Behavior

_No response_

### Other Software

_No response_
Repository: node
Issue: Incorrect normalization of POSIX paths with exactly two leading slashes
Labels: path

### Version

v20.10.0

### Platform

Microsoft Windows NT 10.0.19045.0 x64

### Subsystem

lib/path.js  ("node:path/posix")

### What steps will reproduce the bug?

When I `normalize` a POSIX path with 'node:path/posix', if the path contains **exactly two leading slashes**, I'd expect the two leading slashes **NOT to be collapsed to one**, as per the POSIX spec (see [1]), but the opposite appears to happen.

Here is an example with CMD on Win 10:

```cmd
C:\Users\Julio>node
Welcome to Node.js v20.10.0.      
Type ".help" for more information.
> var $p = require("path/posix")
undefined
> $p.normalize("//alpha/beta")
'/alpha/beta'
```

### How often does it reproduce? Is there a required condition?

Always.

### What is the expected behavior? Why is that the expected behavior?

Expected result is `'//alpha/beta'`, i.e. the two leading slashes are NOT collapsed to one.

### What do you see instead?

Actual result is `'/alpha/beta'`, where the two leading slashes have been collapsed to one.

### Additional information

[1] See [POSIX.1-2017 / Base Definitions / 3.271 Pathname](https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_271), which states:
> Multiple successive slash characters are considered to be the same as one slash, except for the case of exactly two leading slash characters.
Repository: TypeScript
Issue: Low priority inference trumps a much better inference that can be made from a generic signature
Labels: Possible Improvement

### 🔎 Search Terms

inference generic signature type parameters low priority 

### 🕗 Version & Regression Information

- This is the behavior in every version I tried

### ⏯ Playground Link

https://www.typescriptlang.org/play?ts=5.4.0-dev.20240102#code/CYUwxgNghgTiAEAzArgOzAFwJYHtX1ES1RAGEcBbABzxFQwB4AFGHKgZ3hAA8M7hOAJXA4YwBuwwxiAcwA08KKgCeAPlUAKAFDx47EBmRUAXPA1VWHUyzbsAlPAC8q+ADccWYHJ3w22POwA-KYA3j66FrbBZgDWIMo4iPA2HHYA2gC6ANw+AL7edqbmluzWJQ7O8GgxqDgA7qg5WmABGPBw7ACMTgQgRCTk1LT02roMACpcvPycktKoMpoA+pFW8CHwFOwyppO5FS5hurpwhjD4GgfruTm6uVp2TR2dWgD0r-AAeoFaza3tIHYACYeoRiGRKDQSCMfBMpnxUAI9FJZMtVqV1pttrt4PsnIdwgCzhcriEbnlvLojsd0aY0gAiLYyekZSm4gpPQFAt4fb5aIA

### 💻 Code

```ts
declare function defineComponent<Props extends Record<string, any>>(
  setup: (props: Props) => void,
  options?: {
    props?: (keyof Props)[];
  },
): (props: Props) => unknown;

const res1 = defineComponent(
  <T extends string>(_props: { msg: T }) => {
    return () => {};
  }
);

res1
// ^? const res1: <T extends string>(props: { msg: T; }) => unknown

const res2 = defineComponent(
  <T extends string>(_props: { msg: T }) => {
    return () => {};
  },
  {
    props: ["msg"],
  },
);

res2
// ^? const res2: (props: { msg: any; }) => unknown
```


### 🙁 Actual behavior

A low-priority inference made from `keyof Props` prevents inference from the generic signature

### 🙂 Expected behavior

I'd expect both of those to infer the same result: `<T extends string>(props: { msg: T; }) => unknown`

### Additional information about the issue

There is an existential question to be asked here... what is a low-priority inference in the first place? :P Where is the line? Should every inference priority other than `InferencePriority.None` be treated as low-priority **here**?
Repository: godot
Issue: Range.changed signal is unclear.
Labels: discussion,breaks compat,topic:gui

### Tested versions

4.2.1 Stable

### System information

Windows 10

### Issue description

`Range.changed()` signal is unclear. It emits `min_value`, `max_value`, `page`, or `step` change; it does not emit when `value` changes. That is `Range.value_changes(value:float)`.

I suggest renaming this signal to `constraints_changed()` to help clarify what has "changed".



### Steps to reproduce

Create a `Range` node, usually something like a `SpinBox` or `Slider` or similar. Create a script and attach `changed()` signal to it. See it doesn't trigger then the value changes.

### Minimal reproduction project (MRP)

I don't believe this is necessary, but I'll create it if it's requested.
Repository: flutter
Issue: [google_maps_flutter] mapType: MapType.none still shows base map
Labels: p: maps,package,team-ecosystem,has reproducible steps,P2,triaged-ecosystem,found in release: 3.16,found in release: 3.18

### Steps to reproduce

My GoogleMap call (shown for completeness, but focus is on the `mapType` parameter):
```
GoogleMap(
          mapType: MapType.none,
          myLocationEnabled: true,
          myLocationButtonEnabled: true,
          minMaxZoomPreference: isRunningOnIos
              ? const MinMaxZoomPreference(3, 11)
              : const MinMaxZoomPreference(3, 11),
          tiltGesturesEnabled: false,
          zoomGesturesEnabled: true,
          zoomControlsEnabled: true,
          buildingsEnabled: false,
          initialCameraPosition: CameraPosition(
            target: context.read<Gps>().initialPosition,
            zoom: zoomLevel,
          ),
          cameraTargetBounds: CameraTargetBounds(validGpsBounds),
          tileOverlays: tileOverlays,
          markers: planeMarker != null ? {planeMarker!} : const <Marker>{},
          polylines: navigationLines.union(runwayGuideLines),
          polygons: airSigmetPolygons,
          circles: dots,
          onMapCreated: onMapCreated,
          onCameraMove: (cameraPosition) =>
              cameraLatLng = cameraPosition.target,
          onCameraIdle: onCameraIdle,
          onTap: onMapTap,
        )
```

### Expected results

No basemap should be shown, only the `tileOverlays` provided.

### Actual results

On Android, and only in some cases, the base map _does_ show below the tileOverlays. It is unclear when and why this happens.  When I revert back to the plugin version 2.2.8 (instead of latest 2.5.0) then it works as expected, and the base map is never shown.

### Code sample

See above

### Screenshots or Video

_No response_

### Logs

_No response_

### Flutter Doctor output

Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.16.5, on macOS 14.2.1 23C71 darwin-arm64, locale en-US)
[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
[✓] Xcode - develop for iOS and macOS (Xcode 15.0.1)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2023.1)
[✓] Connected device (4 available)
[✓] Network resources

• No issues found!
Repository: neovim
Issue: jobs/processes info, stats, history
Labels: enhancement,performance,job-control

### Problem

Processes (jobs) can be created in various ways. There's no easy way to see a list of jobs or historical stats. Plugins may cause performance issues and troubleshooting this requires external platform-specific tools (gdb/lldb/etc).

### Expected behavior

Nvim should have a global "jobs" table that provides visibility into:

- recent jobs (including terminated jobs)
- job info (start/end times, plugin/source-line that invoked it)

This table should be updated whenever a process is started by:

```
system()
jobstart()
vim.system()
:terminal
nvim_open_term()
vim.uv.spawn (if reasonably feasible)
```

`:checkhealth job` should show a warning if a plugin is causing performance degradation because of expensive or numerous processes.

### Implementation

Hooking into `uv_spawn` would be the most comprehensive way to capture all jobs. But the higher-level info (such as plugin source-line) would need to be plumbed through, where possible.

### Related

- https://github.com/neovim/neovim/issues/25914
- https://github.com/neovim/neovim/issues/19624
- https://github.com/neovim/neovim/issues/557
Repository: deno
Issue: mkdir/mkdirSync does not throw an error when directory already exists and recursive: true
Labels: bug,docs

Version: Deno 1.39.1 (Windows)

The [documentation](https://deno.land/api@v1.39.1?s=Deno.mkdir) for `mkdir` indicates that it throws an error when a directory already exists. However, when I try this locally, I cannot get it to throw an error when `{ recursive: true }` is specified. Example:

```js
Deno.mkdir(".deno-tmp");

// no error thrown
await Deno.mkdir(".deno-tmp", { recursive: true });

// also no error thrown
Deno.mkdirSync(".deno-tmp", { recursive: true });
```

The only [related test](https://github.com/denoland/deno/blob/261f32ef651a6515fbac664302adcfbe34a04372/cli/tests/unit/mkdir_test.ts#L176-L178) I could find seems to indicate that an error is expected only when the path resolves to a file? [These tests](https://github.com/denoland/deno/blob/261f32ef651a6515fbac664302adcfbe34a04372/cli/tests/unit/mkdir_test.ts#L138-L154) seem to indicate that it's expected that `mkdir/mkdirSync` do not throw errors at all when `{ recursive: true }` is passed.

It seems most likely that the documentation is incorrect here, or at the very least, misleading and should be updated.
Repository: godot
Issue: shader compilation very slow in Compatibility renderer
Labels: bug,topic:rendering,performance

### Tested versions

- Reproducible in: 4.2.1 stable
- NOT reproducible in 3.5.2 stable

### System information

macOS Ventura, Android 13 - compatibility

### Issue description

Showing/loading CanvasItem shaders for the first time is much slower when using Compatibility renderer compared to Forward+ or Mobile. It occurs on macOS (2020 Mac Mini M1) and Android (Google Pixel 4 XL), but not on my iPhone 14 Pro Max (compatibility actually seems to be faster there). Unable to test Windows.


Here it is on mobile mode on Mac, a short stutter

https://github.com/godotengine/godot/assets/33777501/e2f09a1e-58a6-497a-b4ce-455d0a856278


and compatibility, much longer stutter

https://github.com/godotengine/godot/assets/33777501/bec8d6ba-69fa-4755-8f85-cea6f71c3f7c


### Steps to reproduce

Run MRP on Mac or Android. After 1 second, the shaders will load and display

### Minimal reproduction project (MRP)

[ShaderCompilationIssue.zip](https://github.com/godotengine/godot/files/13814880/ShaderCompilationIssue.zip)
Repository: go
Issue: x/crypto/ssh: nonstandard `const maxAgentResponseBytes` should be configurable
Labels: NeedsInvestigation

### Go version

go version go1.21.1 darwin/arm64

### What operating system and processor architecture are you using (`go env`)?

```shell
GO111MODULE=''
GOARCH='arm64'
GOBIN=''
GOCACHE='/Users/cweagans/Library/Caches/go-build'
GOENV='/Users/cweagans/Library/Application Support/go/env'
GOEXE=''
GOEXPERIMENT=''
GOFLAGS=''
GOHOSTARCH='arm64'
GOHOSTOS='darwin'
GOINSECURE=''
GOMODCACHE='/Users/cweagans/Developer/go/pkg/mod'
GONOPROXY=''
GONOSUMDB=''
GOOS='darwin'
GOPATH='/Users/cweagans/Developer/go'
GOPRIVATE=''
GOPROXY='https://proxy.golang.org,direct'
GOROOT='/opt/homebrew/Cellar/go/1.21.1/libexec'
GOSUMDB='sum.golang.org'
GOTMPDIR=''
GOTOOLCHAIN='auto'
GOTOOLDIR='/opt/homebrew/Cellar/go/1.21.1/libexec/pkg/tool/darwin_arm64'
GOVCS=''
GOVERSION='go1.21.1'
GCCGO='gccgo'
AR='ar'
CC='cc'
CXX='c++'
CGO_ENABLED='1'
GOMOD='/Users/cweagans/Developer/github.com/swirldslabs/txauth/go.mod'
GOWORK=''
CGO_CFLAGS='-O2 -g'
CGO_CPPFLAGS=''
CGO_CXXFLAGS='-O2 -g'
CGO_FFLAGS='-O2 -g'
CGO_LDFLAGS='-O2 -g'
PKG_CONFIG='pkg-config'
GOGCCFLAGS='-fPIC -arch arm64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -ffile-prefix-map=/var/folders/xh/xytgk13j0v33_8zj9qdtpyh80000gp/T/go-build3042814605=/tmp/go-build -gno-record-gcc-switches -fno-common'
```


### What did you do?

We have an agent protocol extension that can sometimes send a fair amount of data over the agent protocol - more than the 16kb limit imposed by https://cs.opensource.google/go/x/crypto/+/refs/tags/v0.17.0:ssh/agent/client.go;l=156. Since there isn't a limit specified by the agent protocol, I didn't expect that the go library would impose one and ended up spending way too much time narrowing down the problem.

### What did you expect to see?

I expected to be able to send any amount of arbitrary data over the connection.

### What did you see instead?

I could not do that and got this error in my logs: `agent 11: agent: client error: response too large`.
Repository: PowerToys
Issue: Value type incorrectly identified in RegistryPreview
Labels: Issue-Bug,Needs-Triage,Product-Registry Preview

### Microsoft PowerToys version

0.76.2

### Installation method

PowerToys auto-update

### Running as admin

Yes

### Area(s) with issue?

Registry Preview

### Steps to reproduce

1. Create the following `.reg` file:
```reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\_TEST_KEY]
"Test"="hex:ff"
```

2. Open the file with RegistryPreview
3. Select the key `_TEST_KEY` to view its children
4. Observe the value in the preview window
![image](https://github.com/microsoft/PowerToys/assets/11494652/10115e5e-e0f5-4e57-8beb-18819c6fe16f)


### ✔️ Expected Behavior

The value type is correctly represented as `REG_SZ` with the value data containing the string `hex:ff`

| Name | Type | Data |
| --- | --- | --- |
| Test | REG_SZ | hex:ff |


### ❌ Actual Behavior

The value is represented in the preview as `REG_BINARY`:

| Name | Type | Data |
| --- | --- | --- |
| Test | REG_BINARY | 0xFF |

regedit.exe correctly writes the data to the `HKEY_CURRENT_USER\_TEST_KEY` key:

| Name | Type | Data |
| --- | --- | --- |
| Test | REG_SZ | hex:ff |

![image](https://github.com/microsoft/PowerToys/assets/11494652/3caa4ff4-82f5-4b6c-9a84-9b8b92ae90a7)


### Other Software

_No response_