sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: rust
Issue: Follow token restriction disallows keywords after path fragment specifier (and likely others)
Labels: A-macros,T-compiler

I just wanted to add match guard support to the [as_variant](https://docs.rs/as_variant/latest/as_variant/) crate I published yesterday, but found that it was impossible without turning the macro into a token muncher (something I'm not familiar enough with and also find rather unappealing).

Basically, I tried this:

```rust
macro_rules! as_variant {
    ( $enum:expr, $( $variants:path )|* $( if $guard:expr )? ) => { /* ... */ };
}
```

and got the error

```
error: `$variants:path` may be followed by `if`, which is not allowed for `path` fragments
   --> src/lib.rs:120:44
    |
120 |     ( $enum:expr, $( $variants:path )|* $( if $guard:expr )? ) => {
    |                                            ^^ not allowed after `path` fragments
    |
    = note: allowed there are: `{`, `[`, `=>`, `,`, `>`, `=`, `:`, `;`, `|`, `as` or `where`
```

which seems wrong.

Actually after writing most of this report and seeing `as` and `where` in the list I found a workaround that's not token munching, I can use `pat_param` instead of `path`, but I feel like what I wrote originally should still be allowed.
Repository: react
Issue: [DevTools Bug]: Labels are cut off on Firefox on Linux (Fedora 36)
Labels: Type: Bug,Status: Unconfirmed,Component: Developer Tools

### Website or app

https://codesandbox.io/s/hopeful-fog-nxqwgw

### Repro steps

When using React DevTools on **Firefox 104.0.1 (64-bit)** on **Linux (Fedora 36 with Gnome Desktop 42)** the key labels on the right hand pane are cut off. See screenshot. I'm guessing this is likely because of fonts being used on Linux are different from Windows and macOS. I haven't noticed this problem in Chrome at all, and I don't think it happens on Windows and macOS.

This only happens to editable orange/keys in the props panel, when the keys are black/read only, they render just fine.

I also noticed that React devtools doesn't honor the Firefox advanced font settings like the rest of devtools does. Having the ability to select a different browser monospace font will allow for a workaround to this issue.

![Screenshot from 2022-09-14 09-33-08](https://user-images.githubusercontent.com/612695/190090608-602bd0d8-3557-492e-a2d9-59b16372f522.png)


### How often does this bug happen?

Every time

### DevTools package (automated)

_No response_

### DevTools version (automated)

_No response_

### Error message (automated)

_No response_

### Error call stack (automated)

_No response_

### Error component stack (automated)

_No response_

### GitHub query string (automated)

_No response_
Repository: go
Issue: x/pkgsite: Show search bar and package path breadcumbs all the time
Labels: pkgsite

<!--
Please answer these questions before submitting your issue. Thanks!

If you would like to have your package removed, please file an issue at https://golang.org/s/pkgsite-package-removal.
-->
 
### What is the URL of the page with the issue?
 
 Any document on `pkg.go.dev`.
 
### What is your user agent?
 
<!-- 
You can find your user agent here:
https://www.whatismybrowser.com/detect/what-is-my-user-agent
-->
 
`Mozilla/5.0 (X11; Linux x86_64; rv:104.0) Gecko/20100101 Firefox/104.0`
 
 
### What did you do?
 
<!--
If possible, provide a recipe for reproducing the error.
-->
 
* Open any documentation longer than a screenful
 
### What did you expect to see?
 
* Open any documentation longer than a screenful
* Scroll down
* Header containing search bar and package navigation breadcrumb (Like  `Discover Packages > Standard library > container > list` link set) **visible** all the time.
 
 
### What did you see instead?

* Open any documentation longer than a screenful
* Scroll down
* Header containing search bar and package navigation breadcrumb (Like  `Discover Packages > Standard library > container > list` link set) **collapses**.
* You have to scroll all the way up to be able to search or navigate to parent package.
Repository: pytorch
Issue: Segmentation fault in `torch.futures.collect_all`
Labels: module: crash,module: error checking,triaged

### 🐛 Describe the bug

In `torch.futures.collect_all` when `futures` got invalid input, it causes a Segmentation fault.

## code

```python
import torch

input = (None,)

torch.futures.collect_all(futures=input)
```

## output
```bash
Segmentation fault (core dumped)
```

### Versions

PyTorch version: 1.12.1+cu102
Is debug build: False
CUDA used to build PyTorch: 10.2
ROCM used to build PyTorch: N/A

OS: Ubuntu 20.04.4 LTS (x86_64)
GCC version: (Ubuntu 9.4.0-1ubuntu1~20.04.1) 9.4.0
Clang version: Could not collect
CMake version: Could not collect
Libc version: glibc-2.31

Python version: 3.8.10 (default, Jun 22 2022, 20:18:18)  [GCC 9.4.0] (64-bit runtime)
Python platform: Linux-5.4.0-117-generic-x86_64-with-glibc2.29
Is CUDA available: False
CUDA runtime version: No CUDA
GPU models and configuration: No CUDA
Nvidia driver version: No CUDA
cuDNN version: No CUDA
HIP runtime version: N/A
MIOpen runtime version: N/A
Is XNNPACK available: True

Versions of relevant libraries:
[pip3] numpy==1.18.5
[pip3] torch==1.12.1
[conda] Could not collect
Repository: rust
Issue: Complete raw identifier help suggestion for all applicable keywords used as identifiers
Labels: A-diagnostics,T-compiler

<!--
Thank you for filing a bug report! 🐛 Please provide a short summary of the bug,
along with any information you feel relevant to replicating the bug.

If you cannot produce a minimal reproduction case (something that would work in
isolation), please provide the steps or even link to a repository that causes
the problematic output to occur.
-->

Given the following code: [link](https://play.rust-lang.org/?version=nightly&mode=debug&edition=2021&gist=576d9ef1b3ae7e78337fb17b80f8d125)

```rust
fn main() {
    let false = 1;
    let in = 2;
    let mut = 3;
    let ref = 4;
    let true = 5;
}
```

The current output is:

```
Compiling playground v0.0.1 (/playground)
error: expected pattern, found keyword `in`
 --> src/main.rs:3:9
  |
3 |     let in = 2;
  |         ^^ expected pattern

error[[E0308]](https://doc.rust-lang.org/nightly/error-index.html#E0308): mismatched types
 --> src/main.rs:2:9
  |
2 |     let false = 1;
  |         ^^^^^   - this expression has type `{integer}`
  |         |
  |         expected integer, found `bool`

For more information about this error, try `rustc --explain E0308`.
error: could not compile `playground` due to 2 previous errors
```

<!-- The following is not always necessary. -->
Out of all the keywords (strict, reserved and weak), all of them suggest adding the `r#` prefix to make it a raw identifier when used in the above setting, except the ones listed above or those that cant be made into a raw identifier (I just tested all of them). Hence, I think we should extend the raw identifier suggestion to all applicable keywords listed above in the code snippet. This ensures uniformity across the board with regards to this help suggestion. The help suggestion may look like the following (the format for all  help suggestions currently present). Thanks a lot.

```
help: escape `false` to use it as an identifier
  |
2 |     let r#false = 1;
  |         ++
```

<!--
If the problem is not self-explanatory, please provide a rationale for the
change.
-->

<!--
If dramatically different output is caused by small changes, consider also
adding them here.

If you're using the stable version of the compiler, you should also check if the
bug also exists in the beta or nightly versions. The output might also be
different depending on the Edition.
-->
Repository: PowerToys
Issue: Current language indicator close to the text cursor
Labels: Idea-Enhancement,Needs-Triage

### Description of the new feature / enhancement

Bilingual users or those who use more than two languages often fail to type using the right language. Because they have to check the current language every time before the typing by looking at the bottom right corner where usually the language/layout indicator is.

I suggest providing the convenient way to know the current language by using color/shape (other in-place indicator) of the text cursor. This should significantly improve the typing experience for such bilingual users.

There is already an implementation called Aml Maple (http://www.amlpages.com/amlmaple.shtml), but I struggle every time trying to use it as there are different issues arise.

### Scenario when this would be used?

I start typing the right language/layout right away without losing the context.

### Supporting information

_No response_
Repository: rust
Issue: Function type with HRTB and associated type argument unifies inconsistently
Labels: A-lifetimes,A-trait-system,T-compiler,C-bug,A-lazy-normalization,T-types,fixed-by-next-solver,A-higher-ranked

This is a similar issue as #84937, #89436, and #90875. Those were fixed by #90887, but it seems like the issue still exists (on stable and nightly). It is pretty flakey: In this case, it can be fixed by adding a type annotation and even by changing the order of the `exec` function's arguments.

```rs
fn main() {
    // error: mismatched types
    //   expected fn pointer `for<'a> fn(<u32 as Input>::Projected<'a>) -> _`
    //         found fn item `fn(u32) -> u32 {double}`
    //
    // Two ways to fix the problem here:
    // - Add `::<u32, _>` below
    // - Switch the order of the parameters on `exec`
    exec(double, 10);
}

fn double(x: u32) -> u32 {
    2 * x
}

fn exec<In, Out>(f: for<'a> fn(<In as Input<'a>>::Projected) -> Out, input: In) -> Out
where
    In: for<'a> Input<'a>,
{
    todo!()
}

trait Input<'a> {
    type Projected;
}

impl<'a> Input<'a> for u32 {
    type Projected = u32;
}
```

### Full Diagnostic
<details>

```
error[E0308]: mismatched types
  --> src/lib.rs:26:11
   |
26 |     query(double, 10);
   |     ----- ^^^^^^ expected associated type, found `u32`
   |     |
   |     arguments to this function are incorrect
   |
   = note: expected fn pointer `for<'a> fn(<u32 as Input<'a>>::Projected) -> _`
                 found fn item `fn(u32) -> u32 {double}`
   = help: consider constraining the associated type `<_ as Input<'a>>::Projected` to `u32` or calling a method that returns `<_ as Input<'a>>::Projected`
   = note: for more information, visit https://doc.rust-lang.org/book/ch19-03-advanced-traits.html
note: function defined here
  --> src/lib.rs:33:4
   |
33 | fn query<In, Out>(f: for<'a> fn(<In as Input<'a>>::Projected) -> Out, input: In) -> Out
   |    ^^^^^          --------------------------------------------------

For more information about this error, try `rustc --explain E0308`.
```

</details>

### Meta
`rustc --version --verbose`:
```
rustc 1.65.0-nightly (17cbdfd07 2022-09-13)
binary: rustc
commit-hash: 17cbdfd07178349d0a3cecb8e7dde8f915666ced
commit-date: 2022-09-13
host: aarch64-apple-darwin
release: 1.65.0-nightly
LLVM version: 15.0.0
```
cc @jackh726
Repository: ant-design
Issue: Menu should support a new mode where multiple selection is allowed only on ctrl-click
Labels: Inactive

### What problem does this feature solve?

Many UIs support a mode where a single-click on an item selects it and deselects others, and ctrl-click on an item additionally selects (or deselects) it. 

The Menu component should optionally support the same behaviour.

Whilst it might be possible to replicate this by inspecting the DOM event on `onClick`, it would be nicer if built-in to the component.

### What does the proposed API look like?

```<Menu multiple="true|false|ctrl">```

<!-- generated by ant-design-issue-helper. DO NOT REMOVE -->
Repository: create-react-app
Issue:  CRA 5.xx - HMR/Fast-Refresh for any .js or .jsx does not trigger component refresh when eslint is enabled
Labels: needs triage,issue: bug report

When i do some changes in *.js,*.jsx files it is triggering the HMR saying "Compiling..." but there are no changes reflected in the screen until i refresh. But the eslint error overlay is showing the new lint errors, pretty errors i have made yet no changes to the components.

These are my eslint rules.

```
module.exports = {
  env: {
    browser: true,
    es6: true,
    node: true, //remove module not found errors
    jest: true, //remove jest no-undef errors
  },
  parser: "@babel/eslint-parser",
  parserOptions: {
    ecmaFeatures: {
      jsx: true,
    },
    ecmaVersion: 2018,
    sourceType: "module",
    requireConfigFile: false,
    babelOptions: {
      //required or else flow errors eg:- src/index.js @ ReactDOM.render
      presets: ["@babel/preset-react"],
    },
  },
  extends: [
    "eslint:recommended",
    "plugin:react/recommended",
    "plugin:react-hooks/recommended",
    "plugin:prettier/recommended",
  ],
  globals: {
    Atomics: "readonly",
    SharedArrayBuffer: "readonly",
  },
  plugins: ["react", "react-hooks"],
  rules: {
    "no-unused-vars": [
      "error",
      {
        destructuredArrayIgnorePattern: "^_",
        ignoreRestSiblings: true,
      },
    ],
    "no-duplicate-imports": "error",
    "react/display-name": "off",
    "react/prop-types": "off",
    "react/react-in-jsx-scope": "off",
    //"react-hooks/exhaustive-deps": "warn", // change while developing so that the editor or linter can catch useEffect, useMemo, useCallback dependency array issues
    "react-hooks/exhaustive-deps": "off",
    "prettier/prettier": [
      "error",
      {
        endOfLine: "auto",
      },
    ],
  },
};

```

### Environment

Node v16.16.0
npm v8.xx
eslint-plugin-react v7.31.8
eslint-config-prettier v8.5.0
eslint-plugin-prettier v4.0.0

### Expected behavior

When making changes to *.js,*.jsx the HMR or React fast refresh needs to reload the component without requiring a page refresh with eslint enabled.
Repository: pytorch
Issue: Cuda tensor is zero when passed through multiprocessing queue
Labels: module: multiprocessing,triaged

### 🐛 Describe the bug

I encounter an issue when passing cuda tensors through the multiprocessing queue. The first tensor sent is always 0 when using the following code snippet.

```python
import time
import torch
import torch.multiprocessing as mp


def process(q, N):
    for _ in range(N):
        q.put(torch.tensor(1).to("cuda"))
    while True:
        time.sleep(1)


if __name__ == '__main__':
    q = mp.Queue()
    N = 5
    p = mp.Process(target=process, args=(q, N))
    p.start()
    for _ in range(N):
        print(q.get())

````
When running the above code snippet I get: 
```
tensor(0, device='cuda:0')
tensor(1, device='cuda:0')
tensor(1, device='cuda:0')
tensor(1, device='cuda:0')
tensor(1, device='cuda:0')
```
, which is incorrect. The correct result should be to receive only `tensor(1, device='cuda:0')`.
I am able to reproduce this error consistently on multiple versions of pytorch and cuda.
Sometimes the second tensor sent is also corrupted.

Strangely enough, the error does not occur if you create the tensor directly on the cuda device with `torch.ones(1, device="cuda")`.

### Versions

PyTorch version: 1.13.0.dev20220913+cu117
Is debug build: False
CUDA used to build PyTorch: 11.7
ROCM used to build PyTorch: N/A

OS: Microsoft Windows 10 Enterprise
GCC version: Could not collect
Clang version: Could not collect
CMake version: version 3.20.21032501-MSVC_2
Libc version: N/A

Python version: 3.8.10 (tags/v3.8.10:3d8993a, May  3 2021, 11:48:03) [MSC v.1928 64 bit (AMD64)] (64-bit runtime)
Python platform: Windows-10-10.0.19044-SP0
Is CUDA available: True
CUDA runtime version: 11.7.64
GPU models and configuration: GPU 0: NVIDIA GeForce RTX 3090
Nvidia driver version: 516.01
cuDNN version: Could not collect
HIP runtime version: N/A
MIOpen runtime version: N/A
Is XNNPACK available: True

Versions of relevant libraries:
[pip3] numpy==1.23.3
[pip3] torch==1.13.0.dev20220913+cu117
[pip3] torchaudio==0.13.0.dev20220913+cu117
[pip3] torchvision==0.14.0.dev20220913+cu117
[pip3] torchviz==0.0.2
[conda] Could not collect

cc @VitalyFedyunin
Repository: vscode
Issue: `Auto Save` menu state not updated properly (vscode-web)
Labels: bug,menus,confirmed,web

<!-- ⚠️⚠️ 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: 1.71.0
- OS Version: Windows 10 / Ubuntu

Steps to Reproduce:

1. Reload vscode (https://vscode.dev/)
2. Open Settings (UI) and change Auto Save (files.autoSave) default (`off`) value to `afterDelay`
3. Open the File menu
4. See that the `Auto Save` is unchecked
5. Close the menu and reopen
6. See that the value is updated and checked
![Get Started - Workspace - Visual Studio Code - Google Chrome 2022-09-14 10-38-35_Trim](https://user-images.githubusercontent.com/71729183/190135610-20741ae4-7ca6-4cb0-86e4-2e59c3f92274.gif)

Note: this issue also happens using vscode in container and editing `files.autoSave` remot value - then the `Auto Save` in menu not updated after toggle...
Repository: PowerToys
Issue: Keyboard Manager Special Keys Stick (e.g. windows key)
Labels: Issue-Bug,Product-Keyboard Shortcut Manager,Priority-2

### Microsoft PowerToys version

0.62.0

### Running as admin

- [ ] Yes

### Area(s) with issue?

Keyboard Manager

### Steps to reproduce

The commands from my sony wh-1000xm3 headphones touchpad is not recognised by many programs in windows. My keyboard has these commands from my headphones as individual buttons which are recognised by windows. Unfortunately keyboard manager won't let me remap my headphones' "next track" to my keyboard's "next track" for example, as they have the same name (but clearly are different commands as the one from my keyboard works). So I mapped the headphones' "next track" to a buffer key "win+8". I then remapped this shortcut to my keyboard's "next track". It worked like a dream for a bit but then broke (possibly when I updated powertoys). The cause I believe is when I do "next track" on my headphones the buffer windows key gets stuck, i.e. is not unpressed. This means I cannot do the command again and I have to double press the actual windows key to unstick it.

### ✔️ Expected Behavior

To remap the headphones' commands ("previous track", "pause", "next track") to the buttons of the same name/commands on my keyboard. This doesn't work as the buffer windows key that I used gets stuck pressed. 

### ❌ Actual Behavior

When the buffer windows key is executed, it stays pressed rendering the keyboard useless until I press the windows key a couple of times.

![Screenshot 2022-09-14 115442](https://user-images.githubusercontent.com/85358444/190135799-65689ace-0814-40f9-a7d9-be283dfc3bfa.png)


### Other Software

The main software I use it for is music on VLC Media player.
Repository: deno
Issue: Feature request: Web Locks API
Labels: web,suggestion

https://developer.mozilla.org/en-US/docs/Web/API/Web_Locks_API

> The Web Locks API allows scripts running in one tab or worker to asynchronously acquire a lock, hold it while work is performed, then release it. While held, no other script executing in the same origin can acquire the same lock, which allows a web app running in multiple tabs or workers to coordinate work and the use of resources.

I've been looking for some ways to manage access to a single resource, and this seems like it could fill quite a lot of the gap left by shared workers.
Repository: godot
Issue: ExternalTexture missing in Godot 4
Labels: topic:core,regression

### Godot version

Any version of Godot 4

### System information

Any OS version

### Issue description

`ExternalTexture` is missing from Godot 4.

I originally wrote this as a discussion [here](https://github.com/godotengine/godot-proposals/discussions/4902), but when I saw a very similar bug for a different texture (#65349) I figured the same should be done for `ExternalTexture`.

Also, it looks like it is possible to implement this in Vulkan according to [this stackoverflow thread](https://stackoverflow.com/questions/43507536/)

### Steps to reproduce

Right click in the `FileSystem` dock
Choose `New Resource...`
Notice `ExternalTexture` is missing

### Minimal reproduction project

_No response_
Repository: terminal
Issue: Stick profile appearance settings into Theme objects for easier sharing of settings
Labels: Issue-Feature,Product-Terminal,Area-Theming

A fever dream I had:
 
`theme.profile { an appearance }`, and we use that as the "hardcoded default" (or, I suppose the first layer).

That would let folks put the WHOLE appearance of the terminal into a theme, for sharing. background images, background colors, color schemes, fonts, you name it. Now it's just one blob you put into the settings.

Settings from dynamic profiles, `profiles.defaults`, and profile settings would all still take precedence.
Repository: opencv
Issue: QObject::moveToThread: Current thread (0x55dcf63e2610) is not the object's thread (0x55dcf9951b60)
Labels: question (invalid tracker)

QObject::moveToThread: Current thread (0x55dcf63e2610) is not the object's thread (0x55dcf9951b60)

How to disbale this ** annoying message????

It's realllllly reallllly annoying and messedup log mesasgea!
Repository: vscode
Issue: Git - add submodule support to “git checkout”
Labels: feature-request,git

<!-- ⚠️⚠️ 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. -->

`git checkout --recurse-submodules` will be better when a project has git submodules, but vscode's `git checkout to` command doesn't have `--recurse-submodules` option, please support it.
Repository: PowerToys
Issue: FancyZones Editor: customizing zone numbering
Labels: Idea-Enhancement,FancyZones-Editor,Needs-Triage

### Description of the new feature / enhancement

I would appreciate if the user can define the zone numbering.

### Scenario when this would be used?

If im not presenting i am using only my widescreen monitor.
If i am presenting in a meeting, then i use my laptop screen additionally to share my screen.
Because the resolution of my widescreen is not convenient for my colleagues.
(i could share only an application, but this is exhausting if you change applications while presenting)

So i use a fancyzone layout for concentrated working and a layout for presenting.
But if I switch between the layouts, i always have to place my windows from zone 2 to zone 4 and after sharing from zone4 to zone2.

Illustration of my problem:
![FancyZonesEditorNumbering](https://user-images.githubusercontent.com/91615038/190160787-35d9f680-a3d9-439e-bda6-342919bb396c.png)


### Supporting information

_No response_