sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: flutter
Issue: Document the difference between WillPopScope and BackButtonListener
Labels: framework,d: api docs,f: routes,P2,team-framework,triaged-framework

Currently, we have two widgets that can listen for back button presses: WillPopScope and BackButtonListener - this might be confusing.

As far as I can tell difference is that:

The first one is from the Navigator 1.0 world and doesn't support nesting (see https://github.com/flutter/flutter/issues/47088), the latter was recently added and works only with Navigator 2.0 and supports nesting
Repository: TypeScript
Issue: Add support for extesnsions in js files like .native.js, .web.js, .android.js and .ios.js
Labels: Suggestion,Awaiting More Feedback

<!-- ⚠️⚠️ 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. -->
I am working on a react native web project where file extensions can be .js, .native.js, .web.js, .android.js and .ios.js. I would like to know how i can make vscode detect files with such extension in path intellisense when i cmd+click on file path in import statement. If path resolve to multiple files it should show a picker to choose one.

Would like to know if i can configure it in vscode or any extension that can help. I have been searching it for long and can't find any solution. Maybe vscode could provide it out of the box just like webstorm.

Also could not find any help on stackoverflow
[stackoverflow question](https://stackoverflow.com/questions/67422380/how-to-make-vscode-detect-native-js-and-web-js-files-in-path-intellisense)

I know i can use jsconfig.json compilerOptions for custom path resolving using baseUrl and path parameters. But i want to add custom extensions here. Hope my question is clear

Thanks
Repository: pytorch
Issue: Torch.save doesn't make new file
Labels: module: serialization,triaged

## 🐛 Bug

torch.save doesn't make a new file if it doesn't exist.

## To Reproduce

Steps to reproduce the behavior:

I do torch.save(dict, "d1/d2/fname") and the file doesn't exist, it throws an error. 

<!-- If you have a code sample, error messages, stack traces, please provide it here as well -->

## Expected behavior

Intended behaviour should create "d1/d2/fname" even if none of them exist.

## Environment


 - PyTorch Version (e.g., 1.0): 1.7.1
 - OS (e.g., Linux): Linux
 - How you installed PyTorch (`conda`, `pip`, source): conda
 - Build command you used (if compiling from source):
 - Python version: 3.8
 - CUDA/cuDNN version: cudatoolkit=10.1
 - GPU models and configuration: N/A
 - Any other relevant information: N/A

## Additional context

<!-- Add any other context about the problem here. -->


cc @mruberry
Repository: rust
Issue: LLVM-reserved registers can't be used in inline assembly
Labels: A-LLVM,A-inline-assembly,T-compiler,F-asm

On several architectures, some registers are considered reserved by LLVM. These registers effectively can't be used by LLVM's inline assembly instruction as in input/output/clobber.

`rustc` currently [disallows using these registers](https://github.com/rust-lang/rust/pull/84658) in `asm!`. This seems to be in contradiction with [a stated goal in the RFC](https://rust-lang.github.io/rfcs/2873-inline-asm.html):

> The intent is that support for asm! should be independent of the rustc back-end used

As such, I'd expect there to be no backend-specific limitations on inline assembly.

Current LLVM-reserved registers are:

* x86: esi
* x86-64: rbx
* ARM: r7
Repository: vscode
Issue: integrated terminal assumes GNU bash is used as user shell, passes --login
Labels: macos,polish,terminal-profiles

<!-- ⚠️⚠️ Do Not Delete This! bug_report_template ⚠️⚠️ -->
- VS Code Version: unclear, but the user upgraded it recently
- OS Version: unclear, but some kind of Unix or GNU

Steps to Reproduce:

1. set the user shell to `mksh`
2. try to use the integrated terminal

I’m the developer of [mksh](http://www.mirbsd.org/mksh.htm), a Unix Korn Shell. I’m proxying this bugreport for an mksh user.

The user receives the error `The terminal process "/usr/local/bin/mksh '--login'" failed to launch (exit code: 1).` This is because, apparently, vscode forcibly adds the flag `--login`, which only exists in GNU bash, to shell invocations, **which is wrong**.

Many shells have flags to indicate to them they are the login shell, but most often this is `-l` instead, so if you do an `execv("/path/to/shell", "/path/to/shell", "-l", NULL);` they would work, but **that would also be wrong** (even if that’d work with both GNU bash and mksh).

**The _proper_ way to ask a shell to be a _login shell_** is to prepend a hyphen-minus to its zero-th argument, that is: `execv("/path/to/shell", "-shell", NULL);`
You can also prepend the hyphen-minus to the full path: `execv("/path/to/shell", "-/path/to/shell", NULL);`


<!-- 🔧 Launch with `code --disable-extensions` to check. -->
Does this issue occur when all extensions are disabled?: Yes
Repository: TypeScript
Issue: Comments leak into transformer-syntesized lists.
Labels: Bug

# Bug Report

There is a PR #44048 with a fix & test case for this, but it breaks two other tests.

Edited: Made a more minimal and thorough test case.

The TypeScript emitter incorrectly attaches comments into inside of syntesized lists since it thinks the comment after the newly synthesized list should be after the last element of the list. This might not appear anywhere else since I'm not sure if any other code creates such lists in a similar way in transformers like my Pipeline operator experiment for TypeScript.

I do have a fix for this for my issue, but then two existings tests fail. This feels like it could be a bigger bug and my fix is rather specific. .

The minimal case transformer just wraps function calls into a commalist. The transformer also wraps the expression into parens, but it's mainly to make the bug more apparent - the bug happens even without it.
```ts
function wrapInCommaList(context: TransformationContext) {
    return (sourceFile: SourceFile): SourceFile => {
        return visitNode(sourceFile, rootTransform, isSourceFile);
    };
    function rootTransform<T extends Node>(node: T): Node {
        if (isIdentifier(node) || isCallExpression(node)) {
            return factory.createParenthesizedExpression(
                factory.createCommaListExpression([
                    node
                ])
            );
        }
        return visitEachChild(node, rootTransform, context);
    }
}
```

This seems to happen in really specific situations. This bug won't occur if I manually create the same AST shape manually in the transformer that haven't had their pos, end, flags and parents set. Going to investigate this more.

### 🔎 Search Terms

comment trailing emitter transformer
<!--
  What search terms did you use when trying to find an existing bug report?
  List them here so people in the future can find this one more easily.
-->

### 🕗 Version & Regression Information

HEAD and revealed due to my custom changes to TypeScript.
<!-- When did you start seeing this bug occur?

"Bugs" that have existed in TS for a long time are very likely to be FAQs; refer to
  https://github.com/Microsoft/TypeScript/wiki/FAQ#common-bugs-that-arent-bugs

If possible, please try testing the nightly version of TS to see if it's already been fixed.
For npm: `typescript@next`
This is also the 'Nightly' version in the playground: http://www.typescriptlang.org/play/?ts=Nightly

Note: The TypeScript Playground can be used to try older versions of TypeScript.

Please keep and fill in the line that best applies:
-->

### 💻 Code

<!-- Please post the relevant code sample here as well-->
```ts
focus
// Doubles
focus()
// No trailing newline really breaks everything
```

### 🙁 Actual behavior

```ts
(focus
// Doubles
);
// Doubles
(focus()
// No trailing newline really breaks everything);
// No trailing newline really breaks everything
```

### 🙂 Expected behavior

```ts
(focus);
// Doubles
(focus());
// No trailing newline really breaks everything
```
Repository: rust
Issue: rustdoc tests error output without `tidy` is very bad
Labels: T-rustdoc,T-infra,A-compiletest

Note: `tidy` here is the html diff / format tool, not `src/tools/tidy`

From the [1.52 retrospective](https://rust-lang.zulipchat.com/#narrow/stream/241545-t-release/topic/1.2E52.20retrospective): Having this installed would have made it much easier to spot the issue in #84950.
Repository: storybook
Issue: @storybook/addon-jest fails on Webpack 5 and Vite
Labels: bug,addon: jest,builder-webpack5,builder-vite

I've just stepped into an insidious bug related to `@storybook/addon-jest` after I've migrated my Storybook configuration to support `@storybook/builder-webpack5`. Basically there is a dependency, [`upath`](https://www.npmjs.com/package/upath), which heavily depends on [deprecated automatic Node.js polyfills](https://webpack.js.org/blog/2020-10-10-webpack-5-release/#automatic-nodejs-polyfills-removed). You'll try to find some time to do a demonstration, but right now I can describe that stories with Jest tests attached will raise errors like `(0, upath.normalize) is not a function` and suggest a workaround to be applied on `main.js`:

```js
module.exports = {
  core: {
    builder: 'webpack5',
  },
  webpackFinal: (config) => {
    // Workaround for @storybook/addon-jest on Webpack 5
    config.resolve = {
      ...config.resolve,
      alias: {
        ...config.resolve.alias,
        path: require.resolve('path-browserify'),
      },
    };

    return config;
  },
};
```

<!--
**Describe the bug**
A clear and concise description of what the bug is.

**To Reproduce**
Link to a reproduction repo that demonstrates the bug, plus instructions on how to trigger it.

**System**
Please paste the results of `npx sb@next info` here.

**Additional context**
Add any other context about the problem here.
-->
Repository: vscode
Issue: API to represent dead / inactive code
Labels: feature-request,api,editor-api

<!-- ⚠️⚠️ Do Not Delete This! feature_request_template ⚠️⚠️ -->

Language plugins have to resort to custom LSP extensions to achieve a dimming effect for inactive code like in other IDEs:
> ![1d8889f6e2913db87750cccfcf208441](https://user-images.githubusercontent.com/18388795/95929353-a1663a00-0d78-11eb-8a51-313fe3bb30f0.png)

I'd suggest adding an `inactive` or `disabled` [SemanticTokenModifier](https://microsoft.github.io/language-server-protocol/specifications/specification-current/#textDocument_semanticTokens) and using it to style the code like in the picture.

The only question is how to make sure the whole line appears differently (_iff_ the whole line is affected) and not just the portion of each inactive line covered by text, which may look weird.
Repository: ant-design
Issue: Some control doesn't apply the hover style, when mouse move on its label.
Labels: Inactive,⌨️ Accessibility

- [x] I have searched the [issues](https://github.com/ant-design/ant-design/issues) of this repository and believe that this is not a duplicate.



### Reproduction link
[![Edit on CodeSandbox](https://codesandbox.io/static/img/play-codesandbox.svg)](https://codesandbox.io/s/antd-reproduction-template-forked-ciln1?file=/index.js)

### Steps to reproduce
鼠标移动到item1，item4这两个label上。以及移动到item3里的两个radio后的a，b文本上。


### What is expected?
当鼠标移动到相应的label上，对应的控件表现应该和鼠标移动到控件上一样，边框变蓝。
就像我没有指出的其它几个控件：item1,item5是正常的。

### What is actually happening?
鼠标移动到相应的label，控件表现没有发生变化。

| Environment | Info |
|---|---|
| antd | 4.15.4 |
| React | 17.0.2 |
| System | windows10 |
| Browser | chrome, firefox |


<!-- generated by ant-design-issue-helper. DO NOT REMOVE -->
Repository: pytorch
Issue: JIT "optimizations" take way too long 
Labels: oncall: jit

## 🐛 Bug

The initial calls to the loaded TorchScript model take extremely long (even 1000x longer than the non-jit run, 20s vs 0.02s). I understand that some "optimizations" happen under the hood, but this is really broken user experience for a number of reasons:

 1. Not clear what the cause of slow execution is, eg [user issue](https://discuss.pytorch.org/t/nsight-profile-shows-many-pthread-cond-wait-during-the-first-20-iterations/120046), docs do not mention that the initial execution can be extremely slow
 2. Solution `torch.jit.optimized_execution(False)` not mentioned in docs
 3. The optimisation seems to be re-run for different input shape, this is an issue for variable-length input (eg sound waveform)
 4. Why is it it 1000x slower than normal? Can optimisations be run by the user explicitly rather than magically under the hood? If they are run implicitly then they should not make the run 1000x slower (or at least should be clearly documented).



## To Reproduce

Load TorchScript model, run with variable-sized input. Notice extremely slow initial runtimes.

## Expected behavior

Optimisation is fast or does not happen implicitly when calling the model. Optimisation not re-run for inputs of different shape. Clear documentation.

## Environment

```
PyTorch version: 1.9.0.dev20210501+cu111
Is debug build: False
CUDA used to build PyTorch: 11.1
ROCM used to build PyTorch: N/A

OS: Ubuntu 20.04.2 LTS (x86_64)
GCC version: (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0
Clang version: Could not collect
CMake version: version 3.16.3

Python version: 3.8 (64-bit runtime)
Is CUDA available: True
CUDA runtime version: Could not collect
GPU models and configuration: GPU 0: NVIDIA GeForce RTX 3090
Nvidia driver version: 465.19.01
cuDNN version: Could not collect
HIP runtime version: N/A
MIOpen runtime version: N/A

Versions of relevant libraries:
[pip3] numpy==1.19.4
[pip3] pytorch-lightning==1.2.10
[pip3] pytorch-lightning-bolts==0.3.0
[pip3] torch==1.9.0.dev20210501+cu111
[pip3] torch-stft==0.1.4
[pip3] torchaudio==0.9.0.dev20210501
[pip3] torchext==0.0.6
[pip3] torchmetrics==0.2.0
[pip3] torchtext==0.10.0.dev20210501
[pip3] torchvision==0.10.0.dev20210501+cu111
[conda] Could not collect
```


cc @gmagogsfm
Repository: flutter
Issue: Fix text field validator alignment if `filled: true`
Labels: c: new feature,framework,f: material design,a: quality,a: typography,c: proposal,team-design,triaged-design

## Use case

Validator error text will have a padding 

![image](https://user-images.githubusercontent.com/56755783/117538702-0d0f3d80-b010-11eb-9569-a85d0a62f0eb.png)


## Proposal

Have the option to somehow control the padding or move it so that it's attached to the left side regardless if `filled` property is `true` or `false`:

![Group 2890](https://user-images.githubusercontent.com/56755783/117538853-64ada900-b010-11eb-9f9d-13cc6f54f25f.png)

Also, on web, if I hover over the error message "This field cannot be empty", it shows the edit/highlight cursor, I think it should show the regular cursor unless the text field itself is hovered on.
Repository: material-ui
Issue: [SvgIcon] Custom color not supported
Labels: component: Icon,component: SvgIcon

- [x] The issue is present in the latest release.
- [x] I have searched the [issues](https://github.com/mui-org/material-ui/issues) of this repository and believe that this is not a duplicate.

## Current Behavior 😯

I can't use a custom palette color.

## Expected Behavior 🤔

I can use a custom palette color

## Steps to Reproduce 🕹

Steps: 

1. Open https://codesandbox.io/s/customcolor-material-demo-forked-xog2v?file=/demo.js
2. See that the color is wrong

## Context 🔦

Reported by @ahfarmer in https://github.com/mui-org/material-ui/issues/13875#issuecomment-832903570.

It's actually the same for the `Icon` component.

## Your Environment 🌎

v5.0.0-alpha.32
Repository: rust
Issue: rustc segfaults with mimalloc
Labels: A-linkage,I-crash,A-allocators,T-compiler,C-bug

<!--
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.
-->

I have `rustc` installed via `rustup`. Additionally, I'm using [mimalloc](https://github.com/microsoft/mimalloc) as my allocator, loaded with the `LD_PRELOAD` environment variable. Taking a hello-world program and saving it as `main.rs`, running `rustc main.rs` yields:
```
fish: Job 1, 'rustc main.rs' terminated by signal SIGSEGV (Address boundary error)
```
 Running `gdb -ex run --args rustc main.rs` gives me the following output:
```
Reading symbols from rustc...
Starting program: /home/[REDACTED]/.cargo/bin/rustc main.rs
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/usr/lib/libthread_db.so.1".
process 8078 is executing new program: /home/[REDACTED]/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/bin/rustc
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/usr/lib/libthread_db.so.1".
[New Thread 0x7fffee1ff640 (LWP 8089)]

Thread 2 "rustc" received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fffee1ff640 (LWP 8089)]
free (ptr=0x50ddf412300) at ../jemalloc/src/jemalloc.c:2393
2393	../jemalloc/src/jemalloc.c: No such file or directory.
```

If instead, I run `env LD_PRELOAD="" rustc main.rs`, then everything works as expected. I would expect `rustc` to work with a custom allocator.  

### Meta
<!--
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.
-->

`rustc --version --verbose`:
```
rustc 1.52.0 (88f19c6da 2021-05-03)
binary: rustc
commit-hash: 88f19c6dab716c6281af7602e30f413e809c5974
commit-date: 2021-05-03
host: x86_64-unknown-linux-gnu
release: 1.52.0
LLVM version: 12.0.0
```

Running on Arch Linux 5.11.6
</details>
Repository: rust
Issue: Tracking Issue for  `_` as a const argument: `feature(generic_arg_infer)`
Labels: C-tracking-issue,F-generic_arg_infer

This is a tracking issue for the RFC GenericArg::Infer
The feature gate for the issue is `#![feature(generic_arg_infer)]`.

## What is `GenericArg::Infer`?

Currently, rustc supports type inference. That is, given a function `fn(T)`, it can infer the type of T based on its usage. Const-generics also has limited support for inference, such as for arrays, we can infer `N: usize` in some usages `[T; N]`. In order to expand inference for consts, it's necessary to lift the current specialized type `Ty::Infer` into `GenericArg::Infer`, as `GenericArg` covers both consts and types, whereas `Ty::Infer` can only be used in the place of types. This will eventually allow for consts to be inferred in all the same locations as types.

### About tracking issues

Tracking issues are used to record the overall progress of implementation.
They are also used as hubs connecting to other relevant issues, e.g., bugs or open design questions.
A tracking issue is however *not* meant for large scale discussion, questions, or bug reports about a feature.
Instead, open a dedicated issue for the specific matter and add the relevant feature gate label.

### Steps
<!--
Include each step required to complete the feature. Typically this is a PR
implementing a feature, followed by a PR that stabilises the feature. However
for larger features an implementation could be broken up into multiple PRs.
-->

- [x] Implement the RFC (https://github.com/rust-lang/rust/pull/83484)
- [ ] Solve #112110
- [ ] Adjust documentation ([see instructions on rustc-dev-guide][doc-guide])
- [ ] Stabilization PR ([see instructions on rustc-dev-guide][stabilization-guide])

[stabilization-guide]: https://rustc-dev-guide.rust-lang.org/stabilization_guide.html#stabilization-pr
[doc-guide]: https://rustc-dev-guide.rust-lang.org/stabilization_guide.html#documentation-prs

### Unresolved Questions
<!--
Include any open questions that need to be answered before the feature can be
stabilised.
-->

Should `hir::Ty::Infer` be removed?

### Implementation history

<!--
Include a list of all the PRs that were involved in implementing the feature.
-->
Repository: godot
Issue: When a singleton is enabled or disabled (in ProjectSettings), both _enter_tree and _exit_tree are called.
Labels: bug,topic:editor

**Godot version:**
3.3 stable. (Didn't check earlier, but I suspect this has been present for a while / long time.)

**OS/device including version:**
Win10

**Issue description:**
When enabling or disabling autoload singletons in Project Settings, both `_enter_tree` and `_exit_tree` are called on the (tool) singleton (and recursively any nodes inside). I don't know if this is due to technical reasons in the background, but it's quite confusing. The expected behaviour is that `_enter_tree` is called when enabling the singleton (or when editor loads up, or a game scene loads up (F6)), and `_exit_tree` is called when disabling it (or exiting the editor or played scene). It's also weird that `is_inside_tree()` returns true after `_exit_tree` has been called.

**Steps to reproduce:**
- Create an autoload singleton.
- Put inside it methods for `_enter_tree()` and `_exit_tree()` and, say, `print` something to the console.
- (Set up and) toggle the singleton in the Project Settings. (See screenshot.)
![singleton-problem](https://user-images.githubusercontent.com/16601926/117543841-266fb400-b027-11eb-9669-0ddd7d7daf12.jpg)

**Workarounds:**
- If you need to distinguish whether loading or unloading is actually happening (eg. when debugging something), the only way I've found is to check the singleton path in ProjectSettings: If it starts with `*`, then the plugin is (being) enabled, if not, then disabled.

**Minimal reproduction project:**
[SingletonExitTree.zip](https://github.com/godotengine/godot/files/6446027/SingletonExitTree.zip)

**UPDATE**:
It seems it's not actually the same node that receives the enter and exit calls. So the `_enter_tree` and `_exit_tree` calls are correct for that node. However, autoload singleton creates another node somewhere (with same script without calling `_init` or `_ready`), and after the "real" node enters, this other node exits, and right before the real one exits, this other one enters.
  --> Hence, another workaround to check whether `_enter_tree` or `_exit_tree` call is "valid" is to compare `self` to the singleton: `has_node("/root/MySingleton") and get_node("/root/MySingleton") == self`. (<-- Cannot use `MySingleton` directly, because it might have just been unloaded -> parser error.)
Repository: flutter
Issue: OrientationBuilder and desktop screen resize
Labels: framework,f: material design,platform-mac,a: desktop,P2,team-macos,triaged-macos

OrientationBuilder doesn't work on MacOS/desktop - when I resize the screen to one where it should flip the orientation, it doesn't.  This has been implemented for flutter web, so perhaps this is just on someone's "to do" list?  In any case, it should be fixed before release.
```
billf@londo:~$ flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 2.0.6, on macOS 11.2.3 20D91 darwin-arm, locale
    en-US)
[!] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
    ✗ Android license status unknown.
      Run `flutter doctor --android-licenses` to accept the SDK licenses.
      See https://flutter.dev/docs/get-started/install/macos#android-setup for
      more details.
[✓] Xcode - develop for iOS and macOS
[✓] Chrome - develop for the web
[✓] Android Studio (version 4.2)
[✓] IntelliJ IDEA Community Edition (version 2021.1)
[✓] Connected device (2 available)
```