sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: go
Issue: x/text/unicode/bidi: consider reusing internal slices
Labels: NeedsInvestigation

### Go version

go version 1.22

### Output of `go env` in your module/workspace:

```shell
Non relevant
```


### What did you do?

In [go-text/typesetting](https://github.com/go-text/typesetting/blob/d3307102d2cf4faf68a2142375fd31f3ad968e54/shaping/input.go#L202), we use `bidi` to segment the input text. We store and reuse one `bidi.Paragraph` object, calling its `SetString` method for each new input.

### What did you see happen?

The `bidi.Paragraph.prepareInput` method has high memory allocation.

### What did you expect to see?

Only few allocations. If possible, the slices `pairTypes`, `pairValues`, `types` should reuse their capacity (instead of being freed and immediately re-allocated).

On the same topic, `paragraph.determineLevelRuns` allocates a new `run []int` slice, but it is perhaps harder to get rid of this allocation.
Repository: TypeScript
Issue: Elementwise elaboration fails to be found for properties mixed with incompatible index signatures using intersections
Labels: Help Wanted,Possible Improvement

### 🔎 Search Terms

elementwise elaboration errors write type index signature intersection

### 🕗 Version & Regression Information

- This is the behavior in every version I tried

### ⏯ Playground Link

https://www.typescriptlang.org/play/?ts=5.5.0-dev.20240428#code/MYewdgzgLgBFCm0BcMDeMDaBrF0BOAlmAOYC6KYArgLYBG8eMAvjAGRowBmIIuUhJZjAC8HbrxgAiWgEM8k5gG4AUEA

### 💻 Code

```ts
const test: { [k: string]: number } & { foo: string } = { foo: "bar" };
```


### 🙁 Actual behavior

`test` variable gets highlighted

### 🙂 Expected behavior

I'd expect `foo` property in the source to get highlighted

### Additional information about the issue

I don't really expect this to get any meaningful priority ;p it's just something interesting that I noticed while investigating some legitimate question as to why an error is not on the property itself in a more complex situation. Such intersections are flawed on principle so 🤷‍♂️ 

This happens because `elaborateElementwise` uses `getBestMatchIndexedAccessTypeOrUndefined` and that prefers concrete properties on intersections over index signatures. The problem is that you can *read* such dubious properties from the type (and it has a matching type in the example above so it doesn't become an elementwise candidate) but you can't quite write to them.
Repository: vscode
Issue: Feature request: Expose API to get the width and height of the text editors
Labels: api,under-discussion

<!-- ⚠️⚠️ Do Not Delete This! feature_request_template ⚠️⚠️ -->
<!-- Please read our Rules of Conduct: https://opensource.microsoft.com/codeofconduct/ -->
<!-- Please search existing issues to avoid creating duplicates. -->

<!-- Describe the feature you'd like. -->

API to get width and height of:

1. panels
2. windows
3. editors

### Details

My current use case is the extension [vscode-neovim](https://github.com/vscode-neovim/vscode-neovim). This extension integrates neovim into vscode to obtain a good vim mode experience. The basic mode of the extension is to synchronize highlight, text, cursor and other data in two directions. However, due to the lack of viewport APIs in vscode, the size of the viewport is currently hard-coded, and it is also difficult to achieve viewport scrolling synchronization.

Before this, someone filed a similar feature request #195406, but it was closed due to lack of votes. Hope this feature will be considered again.
Repository: rust
Issue: The value no longer satisfies the constraint after passing through `identity`, which seems counterintuitive
Labels: A-type-system,T-compiler,C-discussion,T-types

```rust
use std::convert::identity;

fn foo<F: for<'a> FnOnce(&'a ()) -> &'a ()>(f: F) {
    f(&());
}

fn main() {
    //foo(identity(|x| x));
    foo(|x| x);
}
```

I'm not sure if this is a generic or something issue
Repository: TypeScript
Issue: Error when accessing properties on `globalThis` with the same name of a global variable
Labels: Bug,Help Wanted

### 🔎 Search Terms

globalThis redefined error script property does not exist

### 🕗 Version & Regression Information

- This is the behavior in every version I tried

### ⏯ Playground Link

https://www.typescriptlang.org/play/?noImplicitAny=false&ts=5.5.0-beta#code/DYUwLgBAlgdgbgQ2FAJgRggXggc2AewCMkAVACygGcA6WRZdAbgChRIBPLXA44cq2vCSo0LNhABeXPEVIUadYSgBMLIA

### 💻 Code

```ts
let invalid1 = globalThis.invalid1;
let y = globalThis.invalid1;
let z = globalThis.invalid2;
```


### 🙁 Actual behavior

`Property 'invalid1' does not exist on type 'typeof globalThis'.`

### 🙂 Expected behavior

It should either complain about both `invalid1` and `invalid2`, or neither

### Additional information about the issue

It only happens in scripts and not in modules (if I add `export {}`, there are no reported errors).
Repository: opencv
Issue: Resizing the window doesn't properly scale the image within.
Labels: bug,category: highgui-gui

### System Information

### Steps to reproduce

|property|value|
|---|---|
|operating system | `Linux Mint 21.3 Cinnamon`|
|architecture | `x86`|
|opencv-python version | `4.0.9.80`|

### Detailed description

Resizing the window doesn't properly scale the image within.

Observe the variable padding on the right window border:
![160](https://github.com/opencv/opencv/assets/19511852/0a33154a-4717-4fb6-afd2-df3fbe2a471e)
![161](https://github.com/opencv/opencv/assets/19511852/40c54918-a91b-4d41-9661-aa79d6680515)
![162](https://github.com/opencv/opencv/assets/19511852/1362c980-7434-4e35-97e5-458ac8484282)
![163](https://github.com/opencv/opencv/assets/19511852/65d1ff00-f32e-4118-8ab2-72feb2859825)
![164](https://github.com/opencv/opencv/assets/19511852/aac71c16-d91d-4436-a2c5-3fdd2d752998)
![165](https://github.com/opencv/opencv/assets/19511852/4f1b7ed7-1275-4126-b2b2-5431cc99597e)
![166](https://github.com/opencv/opencv/assets/19511852/81e95366-44d4-48d8-afe1-fb231a9f6fc2)
![167](https://github.com/opencv/opencv/assets/19511852/5bd1ab3b-8b0e-494c-b4f4-203b4676a73f)
![168](https://github.com/opencv/opencv/assets/19511852/21019741-a780-42c3-b533-17263d93d795)
![169](https://github.com/opencv/opencv/assets/19511852/5f2ae8aa-22cb-4375-95ec-01f9cd8da2f7)
![170](https://github.com/opencv/opencv/assets/19511852/34f7c03d-595a-4906-872c-ca0828485de8)


### Steps to reproduce

```python
import numpy as np
import cv2


def main():
    # Generate a random 32x160x3 image
    random_image = np.random.randint(low=0, high=256, size=(32, 160, 3), dtype=np.uint8)

    # Create a named window to display the image
    window_name = 'random image'
    cv2.namedWindow(window_name, cv2.WINDOW_NORMAL)
    cv2.imshow(window_name, random_image)

    # Resize it iteratively
    for width in range(random_image.shape[1]):
        cv2.setWindowTitle(window_name, str(width))
        cv2.resizeWindow(window_name, width, 100)
        cv2.waitKey(50)

    # Exit
    cv2.destroyAllWindows()


if __name__ == '__main__':
    main()
```

### Issue submission checklist

- [X] I report the issue, it's not a question
- [X] I checked the problem with documentation, FAQ, open issues, forum.opencv.org, Stack Overflow, etc and have not found any solution
- [X] I updated to the latest OpenCV version and the issue is still there
- [X] There is reproducer code and related data files (videos, images, onnx, etc)
Repository: deno
Issue: getting file path from `Deno.FsFile`
Labels: public API,suggestion,ext/fs

given a `Deno.FsFile`, there's currently no way to determine path to it's underlying file system file. i suggest adding some kind of api that would allow that, something along

```ts
const file = await Deno.open('file.txt')
assert(file.path == "file.txt")
```

similar to how it's possible in Node.js:

```ts
const file = fs.createReadStream('file.txt')
console.log(file.path) // "file.txt"
```

this is mostly just a developer experience improvement, as it would allow not having to store path to file separately and just reference it from `.path`. and it would also allow library developers to accept the handles returned by `Deno.open` and derive file name directly from them
Repository: rust
Issue: `core::hint::must_use` returns a temporary
Labels: A-lifetimes,T-compiler,C-bug,requires-nightly

Originally noticed in https://github.com/rust-lang/rust/issues/124478#issue-2267570324, @GKFX identified it as a problem in `must_use` in https://github.com/rust-lang/rust/issues/124478#issuecomment-2081492040

I tried this code:

```rust
#![feature(hint_must_use)]

fn foo() -> &'static [usize] {
    &[core::hint::must_use(42)]
}
```

I expected to see this happen:  no error, the value is a constant

Instead, this happened: 

```text
error[E0515]: cannot return reference to temporary value
 --> src/lib.rs:4:5
  |
4 |     &[core::hint::must_use(42)]
  |     ^--------------------------
  |     ||
  |     |temporary value created here
  |     returns a reference to data owned by the current function

For more information about this error, try `rustc --explain E0515`.
error: could not compile `playground` (lib) due to 1 previous error
```

### Meta

rustc 1.79 nightly 2024-04-27
Repository: neovim
Issue: `:highlight Normal` reports "Last set from" non-existing file (with `-V1`)
Labels: bug,lua

### Problem

When I start Neovim with the `-V1` flag, and then do `:highlight Normal`, it reports that this highlight group was last set from a file `<current working directory>/vim/_defaults.lua` (which does not exist). It happens regardless of what the current directory is.

This does not occur for all highlight groups, e.g. not for `Cursor`. My guess would be that it only happens for highlight groups set from the default theme?

### Steps to reproduce

nvim --clean -V1
:highlight Normal

### Expected behavior

"Last set from" should either not appear at all, or point to the location of the default theme? Not sure.

### Neovim version (nvim -v)

NVIM v0.10.0-dev-3032+g61063653b-Homebrew (commit 61063653b06bfccac083c0105ecd0c433b3bb8f7)

### Vim (not Nvim) behaves the same?

No, vim 9.0.1544

### Operating system/version

macOS 13.5.2

### Terminal name/version

kitty 0.31.0

### $TERM environment variable

xterm-kitty

### Installation

brew install --HEAD neovim
Repository: neovim
Issue: Treesitter: Injections lose highlights with 'spell' enabled after scrolling to the right
Labels: bug,highlight,treesitter,spell

### Problem

Injections lose highlights with 'spell' enabled after scrolling to the right.

### Steps to reproduce

nvim --clean -u minimal.lua file.lua
```lua
-- minimal.lua
vim.schedule(function()
    vim.treesitter.start(0, "lua")
    vim.o.spell = true
    vim.o.columns = 48
    vim.cmd("set nowrap") -- i don't know why vim.o errors
    vim.api.nvim_input(":5<cr>w")
end)
```
```lua
-- file.lua
function some_function_which_is_needed_to_repro() end

vim.cmd("ls")
-- look at "ls" and
-- press_w_here________________________________ a
```

### Expected behavior

Injections keep their highlights after scrolling to the right.

### Neovim version (nvim -v)

1 Day old master. https://github.com/neovim/neovim/commit/499070148d8020e1da21b137a94d0aa31a5b65f4

### Vim (not Nvim) behaves the same?

No treesitter in vim.

### Operating system/version

Linux 6.8.1-arch1-1

### Terminal name/version

wezterm and alacritty

### $TERM environment variable

wezterm and alacritty

### Installation

build from source
Repository: rust
Issue: Visited links are made indistinguishable
Labels: A-docs,C-bug,T-release

### Location

https://dev-doc.rust-lang.org/1.78.0/rust.css (used by https://dev-doc.rust-lang.org/1.78.0/releases.html)

### Summary

The stylesheet sets identical styles for `a` and `a:visited`, so it is impossible to distinguish visited links. Visible visited links are an important navigation aid when exploring long lists of links, like release notes. Please add a distinct color for visited links (purple is traditional), or remove colors so that browser default colors are used.
Repository: PowerToys
Issue: Cannot upgrade and cannot uninstall
Labels: Issue-Bug,Area-Setup/Install,Needs-Triage,Needs-Team-Response

### Microsoft PowerToys version

0.78.0

### Installation method

PowerToys auto-update

### Running as admin

No

### Area(s) with issue?

Installer

### Steps to reproduce

Powertoys shows that a new version is available (0.80.1), when I try to install from the General Tab, I get the following error "An error occurred trying to install this update". if I click on try again to download and install, the application closes down and nothing happens.

I have then tried to install by downloading from Github. I tried both the Machine wide and per user installations. Both of them lead to the same error "PowerToys is already installed on this system for current user. We recommend first uninstalling that version before installing this one."

I then went to Settings in Win 11 to uninstall the current version. Surprisingly it appears twice (both of them having been installed on the same date). When I try to uninstall I get exactly the same error as above.

Attached are the logs from both processes. I just changed the name of the user folder for confidentiality reasons (but the structure of the name is consistent).

[powertoys-bootstrapper-msi-0.78.0_20240428171545 - Uninstall failed.txt](https://github.com/microsoft/PowerToys/files/15143857/powertoys-bootstrapper-msi-0.78.0_20240428171545.-.Uninstall.failed.txt)

[powertoys-bootstrapper-msi-0.80.1_20240428171947 - Install failed.txt](https://github.com/microsoft/PowerToys/files/15143858/powertoys-bootstrapper-msi-0.80.1_20240428171947.-.Install.failed.txt)


### ✔️ Expected Behavior

Successful uninstall / install

### ❌ Actual Behavior

Detailed already in steps above. "PowerToys is already installed on this system for current user. We recommend first uninstalling that version before installing this one."


### Other Software

_No response_
Repository: stable-diffusion-webui
Issue: [Feature Request]: Update the gens
Labels: enhancement

### Is there an existing issue for this?

- [X] I have searched the existing issues and checked the recent builds/commits

### What would your feature do ?

update the stability AI and all that generators to the newest versions (I believe it is v3 or 4?) so can get better gens

### Proposed workflow

1. update the submodules and AI gens


### Additional information

_No response_
Repository: deno
Issue: per-scope `JSR_URL`
Labels: suggestion,jsr

in many cases it makes sense to have a separate registry limited to a single scope, similarly to how it's possible in npm

the use-cases for this range from enterprise packages published to a self-hosted instances to various kinds of integration tests, and would also allow to not "populate" the local jsr instance with upstream packages in many cases.

with npm we can use either `.npmrc` or an env variable `npm_config_@scopename:registry`

i suggest deno should support something similar with the `JSR_URL` env variable, something like `JSR_URL_mycompany=https://jsr.mycompany.org` maybe?

and ideally this should also be persisted somewhere, not just an env variable, but that's probably for another feature request
Repository: PowerToys
Issue: Add more touchpad gesture support to Mouse Without Borders
Labels: Needs-Triage,Product-Mouse Without Borders

### Description of the new feature / enhancement

Add support for touchpad three-finger gestures and four-finger gestures in Mouse Without Borders feature.

### Scenario when this would be used?

Used when you use a laptop's touchpad to control a desktop computer, which can significantly improve operating efficiency

### Supporting information

_No response_
Repository: godot
Issue: Path3D section handles move entire Path when the editor is set to half resolution
Labels: bug,topic:editor,topic:3d

### Tested versions

- Reproducible in 4.2.1.stable-mono, 4.2.2.stable-mono, 4.2.2.stable

### System information

Godot v4.2.2.stable - Windows 10.0.22631 - Vulkan (Forward+) - dedicated AMD Radeon RX 6500 XT (Advanced Micro Devices, Inc.; 31.0.24019.1006) - AMD Ryzen 5 4500 6-Core Processor (12 Threads)

### Issue description

Trying to move sections of a Path3D moves the entire Path. Tilting doesn't work at all. The individual section do update though if I change the curves point positions in the inspector.

Here is a video of it: https://youtu.be/CGzK-mETQhU

### Steps to reproduce

Honestly. I don't know. I made three new projects with the different versions mentioned above. In the first few minutes everything works as expected, but some time later it breaks again. I don't know what I'm doing that breaks it.

### Minimal reproduction project (MRP)

[GodotPath3dBug_MRP.zip](https://github.com/godotengine/godot/files/15144247/GodotPath3dBug_MRP.zip)
Repository: storybook
Issue: [Bug]: type error for required props when reusing story definitions according to the docs
Labels: bug,typescript,csf3,sev:S3

### Describe the bug

When reusing story definitions according to [the docs](https://storybook.js.org/docs/writing-stories/stories-for-multiple-components#reusing-story-definitions) I get TypeScript type errors because the StoryObj helper type makes all arguments optional. Storybook should offer a workaround to use this pattern without any type errors.


### To Reproduce

https://stackblitz.com/edit/github-yr2rcr?file=src%2Fstories%2FButton.stories.tsx

Check the Primary story.

### System

```bash
System:
    OS: macOS 14.4.1
    CPU: (10) arm64 Apple M1 Pro
    Shell: 3.6.1 - /opt/homebrew/bin/fish
  Binaries:
    Node: 20.8.0 - ~/.local/share/nvm/v20.8.0/bin/node
    Yarn: 3.4.1 - ~/.local/share/nvm/v20.8.0/bin/yarn <----- active
    npm: 10.1.0 - ~/.local/share/nvm/v20.8.0/bin/npm
  Browsers:
    Chrome: 124.0.6367.91
    Edge: 115.0.1901.200
    Safari: 17.4.1
  npmPackages:
    eslint-plugin-storybook: ^0.6.13 => 0.6.15
```


### Additional context

_No response_
Repository: TypeScript
Issue: Strange runtime caching bug involving `as const` and `const T` generic
Labels: Help Wanted,Possible Improvement

### 🔎 Search Terms

`is:issue runtime caching as const `

### 🕗 Version & Regression Information

- This is a type checker runtime inconsistency
- This is the behavior in every version I tried since const generics were introduced


### ⏯ Playground Link

https://www.typescriptlang.org/play/?target=99#code/C4TwDgpgBA8gRgKwgY2AMQE4HsC2BRAO2AwEsIBnAHgBUA+KAXimqggA9gICATcqDCAENuWAgBsQUANokCAMwgYoAaQiT2nHn3LFZAcygAfKAQCuOOIqNRyIC1jEAaKLIVKAaoLGmIAXSm+AFBQUAD8UADe0gDWai4EKmq+AFxQnt7QAL7BUKkEEABuigDcgYGgkIkg6T4ACoIkGFR0jJE5UsrxULEgWHLMKdLKztQdvr6lmVI9fQOlgexgWBjAUHKmBKgkolA4gmDwSKiEuhSUOciiOsysHFy8UFiIKMCOF1er1ACy+5Dct5oHlIdKQCAZjGYLFZjLZ7E4oBtogQsAB3Ai+N60AAUOSeCFS1DeIT2YEgGFSWKkgmccEGqmqXjqDSaNFoAEpGPRvr8INw3mzUocXphcCdSGduaTeQF6BEcgB6eUAAWA5AAtIsXhqMNglABBMQCYSSMDYMkSKAVXmWgAW2FMehttug5BIegIgmApgEOQEXowCSFqAAdHJsPgiOLyFig8Bg1xTtG8WzgySsSSyWy2ZMypcCNdONcmCTY2KyNGooJUgBGGmpABMUEyzkpbGcIF8HIY9CkbagHezZSAA

### 💻 Code

```ts
type ObjectFromEntries<T> = T extends readonly [infer Key extends string | number | symbol, infer Value][]
  ? { [key in Key]: Value }
  : never;

type KeyValuePairs<T> = {
  [K in keyof T]: [K, T[K]];
}[keyof T];

export function mapObjectEntries<
  const T extends object,
  const TMapped extends [string | number | symbol, unknown],
>(
  obj: T,
  mapper: ([a, b]: KeyValuePairs<T>) => TMapped,
): ObjectFromEntries<TMapped[]> {
  //@ts-expect-error Already properly typed through the signature
  return Object.fromEntries(Object.entries(obj).map(mapper));
}

const test = mapObjectEntries({ a: 1, b: 2 }, ([x, y]) => [x, y]);
```


Here is a screencast illustrating the issue:

https://github.com/microsoft/TypeScript/assets/7313176/4875d16f-6a42-47a4-8f9c-2bd165de7a2c






### 🙁 Actual behavior

Type checker is context sensitive. When I add an `as const` behind the expression (see screencast), it compiles fine even after I remove the `as const` again.

### 🙂 Expected behavior

Consistency

### Additional information about the issue

_No response_
Repository: godot
Issue: Dragging nodes to a C# file in editor handles it as GDScript
Labels: bug,topic:editor

### Tested versions

v4.2.2 Stable Mono [15073afe3]

### System information

Windows 10 - Godot v4.2.2.stable.mono.official

### Issue description

Dragging and dropping a node to the script editor window ignores the currently opened file's language, and inserts a GDScript snippet into the .cs file. Either `$ExampleNode`, or `@onready var example_node = $ExampleNode` if done while holding Ctrl.

This is of course invalid code for C#.

**Expected behavior:** Either insert C# code or just do nothing if the active file's extension does not match .gd


![gdscriptursilly](https://github.com/godotengine/godot/assets/31190904/d9683221-d0f3-46dc-b25c-acd4e742d140)


### Steps to reproduce

1. Create and attach a C# script to a node.
2. Drag and drop any node to the script window, to quick insert a reference to it.

### Minimal reproduction project (MRP)

N/A
Repository: ollama
Issue: Add support for  Qwen-VL
Labels: feature request

https://huggingface.co/Qwen/Qwen-VL
Repository: PowerToys
Issue: Keyboard Manager mapping always fails shortcuts after using one end time Sleep Wake system
Labels: Issue-Bug,Product-Keyboard Shortcut Manager,Needs-Triage

### Microsoft PowerToys version

0.80.1

### Installation method

GitHub

### Running as admin

Yes

### Area(s) with issue?

Keyboard Manager

### Steps to reproduce

Keyboard Manager mapping always fails shortcuts after using one end time Sleep Wake system.

The invalid shortcut map is the one that contains win.
For example, in my configuration:
win+i----> win+up

![image](https://github.com/microsoft/PowerToys/assets/147302873/c16441a9-fdef-480d-9842-50cccc4fc035)

[PowerToysReport_2024-04-29-10-26-19.zip](https://github.com/microsoft/PowerToys/files/15144715/PowerToysReport_2024-04-29-10-26-19.zip)

Yes ,running as admin!


### ✔️ Expected Behavior

Shortcut mapping with win is working properly

### ❌ Actual Behavior

d

### Other Software

none
Repository: ant-design
Issue: Popover 滚动到边缘，页面会出现滚动条
Labels: 🐛 Bug,Inactive

### Reproduction link

[![Edit on StackBlitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/edit/react-nncsjv?file=demo.tsx)

### Steps to reproduce

滚动到最右侧，打开 Popover，向左滚动，观察页面底部


### What is expected?

页面底部没有滚动条

### What is actually happening?

页面底部出现滚动条

| Environment | Info |
| --- | --- |
| antd | 5.16.5 |
| React | latest |
| System | mac |
| Browser | chrome |

<!-- generated by ant-design-issue-helper. DO NOT REMOVE -->
![image](https://github.com/ant-design/ant-design/assets/47104575/c709b28c-a32a-414d-a39a-369619a492cc)