sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: pytorch
Issue: Support views in custom autograd functions
Labels: module: autograd,triaged,enhancement,actionable,tensor subclass

### 🐛 Describe the bug

Currently this fails:

```
        class Alias(Function):
            @staticmethod
            def forward(ctx, input):
                return input[:]
            
            @staticmethod
            def backward(ctx, grad):
                return grad
    
        base = torch.tensor([1.0], requires_grad=True)
        z = base * 1
        x = Alias.apply(z)
        z.mul_(-1)
        x.sum().backward()
        self.assertEqual(base.grad, torch.tensor([-1.0]))
```

with

```
    x.sum().backward()
RuntimeError: Output 0 of AliasBackward is a view and its base or another view of its base has been modified inplace. This view was created inside a custom Function (or because an input was returned as-is) and the autograd logic to handle view+inplace would override the custom backward associated with the custom Function, leading to incorrect gradients. This behavior is forbidden. You can fix this by cloning the output of the custom Function.
```

But we can actually support this today after XLA added the concept of view function. We just stash the custom autograd function in the view function and then replay it (lazily) when the base got mutated. Gradients would be preserved in this case.

Lack of support for this is causing this test to fail in NegativeTensor: https://github.com/albanD/subclass_zoo/blob/722bb0b503430a0781771cc75f6ac1cc0a1b48f1/negative_tensor.py#L130-L141 (and unfortunately, we don't even get a good error message for this case!)

### Versions

master

cc @albanD @zou3519 @gqchen @pearu @nikitaved @soulitzer @Lezcano @Varal7 @msaroufim @ezyang
Repository: rust
Issue: `-D warnings` should deny warnings from lint renames
Labels: A-diagnostics,T-compiler

### Description

e.g: setting `-W clippy::disallowed_type -D warnings` when invoking clippy currently results in the following warning:

```
warning: lint `clippy::disallowed_type` has been renamed to `clippy::disallowed_types`
  |
  = note: requested on the command line with `-W clippy::disallowed_type`
```

...when this should be a hard error (due to the `-D warnings`)

### Version

```text
rustc 1.59.0 (9d1b2106e 2022-02-23)
binary: rustc
commit-hash: 9d1b2106e23b1abd32fce1f17267604a5102f57a
commit-date: 2022-02-23
host: x86_64-pc-windows-msvc
release: 1.59.0
LLVM version: 13.0.0
```
Repository: vscode
Issue: Debugger does not respect supportsDelayedStackTraceLoading false
Labels: bug,debug

<!-- ⚠️⚠️ 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. -->

<!-- 🪓 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.64.2
- OS Version: Windows_NT x64 10.0.19044

When the supportsDelayedStackTraceLoading is false or missing the debugger still makes a request with a limited `levels`:

```
-> stackTraceRequest
{
  command: 'stackTrace',
  arguments: { threadId: 4, startFrame: 0, levels: 20 },
  type: 'request',
  seq: 15
}
```

php-debug did not have an implementation for `startFrame` and `levels`, so when a stack of more than 20 levels happened, one could infinitely request "Load All Stack Frames".

The [feature](https://github.com/xdebug/vscode-php-debug/pull/759) is being implemented, but wanted to point out this nevertheless. 

Btw. If the supportsDelayedStackTraceLoading  is set to true, there are two stackTraceRequests - as expected and already discussed in other GH issues.
Repository: vscode
Issue: Cannot open menu via shortcut when activity bar is hidden
Labels: bug,menus

Does this issue occur when all extensions are disabled?: Yes

- VS Code Version: 1.64.2
- OS Version: 10.0.19044

Steps to Reproduce:

1. Set the following `"window.menuBarVisibility": "compact"`
3. Toggle the activity bar so that it is hidden (`Ctrl`+`Shift`+`P` then type "View: Toggle Activity BarVisibility")
4. Hit `Alt`+`f`

Expected behavior: file menu shows

Actual behavior: nothing happens

Same goes for any of the other menus that one would normally expect to access by using the `Alt`+Letter shortcut.
Repository: go
Issue: x/net/httpproxy: useProxy rejects localhost/loopback addresses unnecessarily
Labels: NeedsInvestigation

The useProxy function automatically returns false if it decides the target host is ```localhost``` or a loopback address @ https://cs.opensource.google/go/x/net/+/master:http/httpproxy/proxy.go;drc=c6ed85c7a12db1bd15e993fd3ae4700b2e9f2c84

```go
if host == "localhost" {
	return false
}
ip := net.ParseIP(host)
if ip != nil {
	if ip.IsLoopback() {
		return false
	}
}
```

It appears to be just about the only proxy implementation that does this.  A good gitlab blog has done a comparison at https://about.gitlab.com/blog/2021/01/27/we-need-to-talk-no-proxy/

There seem to be many valid cases for wanting communications to localhost also proxied.  For example, I have setup a docker registry I would like to test listening at ```localhost:9000``` and wish to use```mitmproxy``` on port 8080 to dump the traffic between a client and this testing registry, to analyse the API calls the client is making.

If you do the obvious thing of setting up docker to use ```http_proxy=http://localhost:8080``` the traffic is never proxied to ```localhost:9000```.  I'm not sure anyone really expects this; for example even the docker proxy information page https://docs.docker.com/network/proxy/ examples are showing setting ```127.0.0.0/8``` in the ```noProxy``` (maybe it works differently on Windows, where you do require this to not proxy localhost? That seems to make the difference just even more confusing.  Searching shows plenty of other examples of people not assuming that localhost/127* are being excluded automatically).

Perhaps there are older comments, I wasn't sure how to track back further than https://cs.opensource.google/go/x/net/+/c7086645de248775cbf2373cf5ca4d2fa664b8c1

Is there any reason why this loopback avoidance shouldn't just be removed in favour of just obeying what is in ```no_proxy```, to bring this in line with most other implementations?
Repository: electron
Issue: [Feature Request]: IAP for Microsoft Store
Labels: enhancement :sparkles:

### Preflight Checklist

- [X] I have read the [Contributing Guidelines](https://github.com/electron/electron/blob/main/CONTRIBUTING.md) for this project.
- [X] I agree to follow the [Code of Conduct](https://github.com/electron/electron/blob/main/CODE_OF_CONDUCT.md) that this project adheres to.
- [X] I have searched the [issue tracker](https://www.github.com/electron/electron/issues) for a feature request that matches the one I want to file, without success.

### Problem Description

In App Purchase Microsoft Store is not possible at the moment. Will this be added in the future? It is becoming a problem given that Microsoft no longer allows companies to push paid apps into the company portal - they must be free apps (with IAP). 

### Proposed Solution

In App Purchase Microsoft Store

### Alternatives Considered

None

### Additional Information

_No response_
Repository: TypeScript
Issue: [vscode] Highlight default node libraries
Labels: Suggestion,Awaiting More Feedback

# Suggestion

<!--
  Please fill in each section completely. Thank you!
-->

## 🔍 Search Terms

<!--
  💡 Did you know? TypeScript has over 2,000 open suggestions!
  🔎 Please search thoroughly before logging new feature requests as most common ideas already have a proposal in progress.
  The "Common Feature Requests" section of the FAQ lists many popular requests: https://github.com/Microsoft/TypeScript/wiki/FAQ#common-feature-requests

  Replace the text below:
-->

vscode highlighting node default libraries

## ✅ Viability Checklist

<!--
   Suggestions that don't meet all these criteria are very, very unlikely to be accepted.
   We always recommend reviewing the TypeScript design goals before investing time writing
   a proposal for ideas outside the scope of the project.
-->
My suggestion meets these guidelines:

* [x] This wouldn't be a breaking change in existing TypeScript/JavaScript code
* [x] This wouldn't change the runtime behavior of existing JavaScript code
* [x] This could be implemented without emitting different JS based on the types of the expressions
* [x] This isn't a runtime feature (e.g. library functionality, non-ECMAScript syntax with JavaScript output, new syntax sugar for JS, etc.)
* [x] This feature would agree with the rest of [TypeScript's Design Goals](https://github.com/Microsoft/TypeScript/wiki/TypeScript-Design-Goals).


## ⭐ Suggestion

<!-- A summary of what you'd like to see added or changed -->

I was directed to file an issue here from vscode team here https://github.com/microsoft/vscode/issues/144218 I'll reiterate some of the information from that issue here.

It seems that the vscode team removed grammars relating to all default libraries in their textmate grammars and instead solely rely on semantic highlighting on default libraries. 

So my request now is to recognize node built-in libraries in typescript itself so vscode gets the full benefits for semantic highlighting. From my limited understanding, if TS recognized these default node libraries then vscode would start highlighting these libraries again. Thanks!

## 📃 Motivating Example

<!--
  If you were announcing this feature in a blog post, what's a short explanation that shows
  a developer why this feature improves the language?
-->

Default libraries in browsers such as `console`, `window`, and `JSON` are all highlighted fine and receive the appropriate tokens.

![image](https://user-images.githubusercontent.com/7419947/156268917-ee246815-db17-4277-aa80-b39768f0833c.png)

## 💻 Use Cases

<!--
  What do you want to use this for?
  What shortcomings exist with current approaches?
  What workarounds are you using in the meantime?
-->

Default libraries from node receive no tokens for `variable.defaultLibrary` in vscode.

![image](https://user-images.githubusercontent.com/7419947/156268905-c6cea4dc-f92c-447e-ad6c-745336a430b6.png)
Repository: godot
Issue: GPUParticles2D's speed scale with scale curve cause texture flickering
Labels: bug,topic:rendering,regression

### Godot version

62765fb

### System information

W10, RX 480, Vulkan

### Issue description

If you set the speed scale property to a low value, and you use a scale curve, you'll see a white texture flicking  across the the GPUParticles2D render area.  

 If you have a low speed scale value, and remove the scale curve, it removes the flickering though. It seems whenever a low speed scale property is working in unison with a scale curve, it creates the flickering

 
Video: https://i.gyazo.com/14db2df4287ef29d1587fb67763b14b0.mp4

### Steps to reproduce

I created an example project

### Minimal reproduction project

 
[godot_gpuparticles2d_scale_flickering_bug.zip](https://github.com/godotengine/godot/files/8165702/godot_gpuparticles2d_scale_flickering_bug.zip)
Repository: vscode
Issue: Text selection highlight dissappears after right-clicking text in textbox
Labels: bug,themes

Issue Type: <b>Bug</b>

I think this is a Windows-specific issue (couldn't repro on macOS).

1. Open a project/folder with Git repo
2. Go to Source Control tab
3. Type some text into the commit message text box
4. Select a portion of the text
5. Right click

Notice both the blue selection highlight and the focus ring around the textbox both disappear.

https://user-images.githubusercontent.com/9157833/156273900-3938d43a-e8af-41eb-8e78-48cf4fc268dd.mp4

VS Code version: Code 1.64.2 (f80445acd5a3dadef24aa209168452a3d97cc326, 2022-02-09T22:02:28.252Z)

OS version: Windows 11 21H2
Restricted Mode: No

<details>
<summary>System Info</summary>

|Item|Value|
|---|---|
|CPUs|Intel(R) Core(TM) i7-9700 CPU @ 3.00GHz (8 x 3000)|
|GPU Status|2d_canvas: enabled<br>gpu_compositing: enabled<br>multiple_raster_threads: enabled_on<br>oop_rasterization: enabled<br>opengl: enabled_on<br>rasterization: enabled<br>skia_renderer: enabled_on<br>video_decode: enabled<br>vulkan: disabled_off<br>webgl: enabled<br>webgl2: enabled|
|Load (avg)|undefined|
|Memory (System)|31.85GB (16.69GB free)|
|Process Argv|. --disable-extensions --crash-reporter-id 2d23e25e-efd7-4bb7-873c-c4b028e7ecc5|
|Screen Reader|no|
|VM|0%|
</details>Extensions disabled
<!-- generated by issue reporter -->
Repository: angular
Issue: extended diagnostics: show warning if component variable is shadowed by template reference
Labels: feature,help wanted,area: compiler,feature: under consideration,compiler: extended diagnostics

### Which @angular/* package(s) are relevant/related to the feature request?

compiler-cli

### Description

Re-opening https://github.com/angular/angular/issues/15956 as a feature request for extended diagnostics. With the introduction of the extended diagnostics in the compiler, this warning would fit quite nicely and would be possible there.


```
class Comopnent {
     public name:string;
}

<div #name="ngName">
</div>
```
Repository: godot
Issue: Cannot convert self to subclass in the code editor
Labels: bug,topic:gdscript

### Godot version

3.4.3.stable

### System information

win7, gles3

### Issue description

Cannot convert `self` to subclass in the code editor, but others can

### Steps to reproduce

Normal conditions: 

```gdscript
class Super:
	pass
class Sub extends Super:
	pass
var super:Super = Super.new()
var sub:Sub = super as Sub
```
`self` conditions: 
```gdscript
extends CollisionObject2D

var this:KinematicBody2D = self as KinematicBody2D # This will result in an error tip in the code editor
# var this:KinematicBody2D = self as CollisionObject2D # no error

func _physics_process(delta: float) -> void:
	...
	push_velocity = this.move_and_slide(push_velocity)
	...
```

### Minimal reproduction project

_No response_
Repository: react
Issue: Bug: element.current.scrollIntoView() not working as expected in chrome.
Labels: Component: DOM,Status: Unconfirmed,Resolution: Needs More Information

Hey 🙋‍♂️

I have built a simple chatbot using react, and when the user sends a message i want to show the last message in the chatWindow component, so I used the following code:
```js
useEffect(
    function () {
      if (lastmessageRef.current !== null) {
        lastmessageRef.current.scrollIntoView()
      }
    },
    [lastmessageRef]
  )
```
It works as expected in edge and Firefox, but on chrome it is behaving weird
llink-to-the-chatbot: https://karthik2265.github.io/worlds-best-chatbot/
github-repo-link: https://github.com/karthik2265/worlds-best-chatbot

Thank you
Repository: next.js
Issue: Import ESM Externals Error only when linking a local package
Labels: bug

### Verify canary release

- [X] I verified that the issue exists in Next.js canary release

### Provide environment information

    Operating System:
      Platform: darwin
      Arch: arm64
      Version: Darwin Kernel Version 21.3.0: Wed Jan  5 21:37:58 PST 2022; root:xnu-8019.80.24~20/RELEASE_ARM64_T8101
    Binaries:
      Node: 16.13.0
      npm: 8.5.2
      Yarn: 1.22.15
      pnpm: 6.32.2
    Relevant packages:
      next: 12.1.1-canary.5
      react: 17.0.2
      react-dom: 17.0.2

### What browser are you using? (if relevant)

_No response_

### How are you deploying your application? (if relevant)

_No response_

### Describe the Bug

I have a package in my `node_modules` which uses an ESM package (`is-stream@^3.0.0`). The package using the ESM package is trying to `require` it which I know is an error and I have raised an issue in the downstream package [here](https://github.com/torusresearch/solana-embed/issues/31). This is fine as next offers a great option `experimental.esmExternals: 'loose'` in order to fix this issue. 

The bug that I have noticed is that so long as I have installed the package (in my example it's `@monsonjeremy/esm-external-package`) I don't even need to enable `experimental.esmExternals: 'loose'`, I am able to run the application just fine without getting this [error](https://nextjs.org/docs/messages/import-esm-externals). If however I link to the package locally, then I get the error:
```txt
ESM packages (is-stream) need to be imported. Use 'import' to reference the package instead. https://nextjs.org/docs/messages/import-esm-externals
```

I am really confused why linking has different behavior then installing the package from NPM and if this is expected.

### Expected Behavior

I should have uniform behavior when linking the package locally or installing it from NPM.

### To Reproduce

I have created an example repo here, which can be used to see the issue: https://github.com/monsonjeremy/esm-external-example-repo

Steps:
1. Clone the repo
2. Run `cd example-package`
3. Run `npm install && npm run build && npm link`
4. Now go to the next app directory `cd ../example-app`
5. Run `npm install`
6: Run `npm run dev`
7. See that the page is able to load as expected on `localhost:3000`
8. Stop the server and run `npm link @monsonjeremy/esm-external-package`
9. Restart the server with `npm run dev`
10. See that localhost:3000 now has an error: 
```txt
ESM packages (is-stream) need to be imported. Use 'import' to reference the package instead. https://nextjs.org/docs/messages/import-esm-externals
```
Repository: vscode
Issue: Context switching prevents external keyboard input in Terminal (iPadOS Safari)
Labels: bug,help wanted,editor-input,ios-ipados,confirmation-pending,terminal-input

- Not specific to any extension
- VS Code Version: 1.64.2 (GitHub Codespaces)
- OS Version: iPadOS 15.3.1

Steps to Reproduce:

1. Open any GitHub repo in GitHub’s VScode Web Editor (pressing `.` key on any repo)
2. Create a Codespace or connect to a Codespace (since Terminal is only accessible within a Codespace/Devcontainer)
3. Type text in terminal (`Command` + `J` to focus it) and it should print as expected
4. Switch focus to another app with Command + Tab 
5. Switch back to VScode/Codespaces, at which point input is no longer possible without first disconnecting and reconnecting the external keyboard (or perhaps triggering the on-screen keyboard some other way) or triggering input with tap events.

Video reproduction: 

https://user-images.githubusercontent.com/65950/156302760-97139ece-5356-4f0a-b965-858e845704b8.MOV

Expected behavior: 

If the keyboard focus is on the terminal the active input device should regain focus when OS context switches back to VSCode. This very well could be an iPadOS Safari bug, but if so it seemed important to document it here since I couldn’t find a specific issue covering this unexpected and disruptive behavior.
Repository: pytorch
Issue: addcdiv is failing the ASAN test for zero divisors
Labels: module: error checking,module: tests,triaged

See [this CI run](https://github.com/pytorch/pytorch/runs/5350307603) for an example. Zero division is no longer undefined behavior since integer inputs are disallowed

```py
dtype = torch.int

input = torch.tensor(1, dtype=dtype)
tensor1 = torch.tensor(1, dtype=dtype)
tensor2 = torch.tensor(0, dtype=dtype)

print(torch.addcdiv(input, tensor1, tensor2))
```

```
RuntimeError: Integer division with addcdiv is no longer supported, and in a future  release addcdiv will perform a true division of tensor1 and tensor2. The historic addcdiv behavior can be implemented as (input + value * torch.trunc(tensor1 / tensor2)).to(input.dtype) for integer inputs and as (input + value * tensor1 / tensor2) for float inputs. The future addcdiv behavior is just the latter implementation: (input + value * tensor1 / tensor2), for all dtypes.
```

and `dtype = torch.float` exhibits the correct behavior

```
tensor(inf)
```

We are probably missing a

https://github.com/pytorch/pytorch/blob/2cefbb71cf65696e28ee1bdfce06d6846285e5fb/c10/macros/Macros.h#L27-L28

annotation there.

---

This was detected in #71561 because by chance `addcdiv` never hit a zero divisor with the random seed we chose. The PR will exclude zeros in the divisor, but this should be removed as soon as this issue is resolved.


cc @mruberry
Repository: vscode
Issue: Support web workers for a remotely installed web extension loaded in the web extension host
Labels: feature-request,extension-host,web

In VS Code for the Web with Codespaces, when loading a remotely installed web extension in web extension host then invoking a web worker by such a web extension is not supported. This is because loading resources from such a web worker will fail.
Repository: PowerToys
Issue: PowerRename default cursor location
Labels: Idea-Enhancement,Product-PowerRename,Needs-Triage

### Description of the new feature / enhancement

It would be more helpful if, when opening PowerRename, that the cursor is automatically in the "Search for" search box. Otherwise, you need to click the mouse into the "Search for" box before typing the search criteria.

### Scenario when this would be used?

One less click when using PowerRename.

### Supporting information

_No response_
Repository: PowerToys
Issue: Keyboard manager display/modify system mapped keys
Labels: Idea-Enhancement,Product-Keyboard Shortcut Manager,Needs-Triage

### Description of the new feature / enhancement

Could the keyboard manager be extended to display a list of all keys which are currently hooked/intercepted with an indication of what they are hooked to. Some key combinations produce odd effects and knowing why is often a hit and miss task of just ploughing through control panel and enabling/disabling things to see if something changes. 


### Scenario when this would be used?

After switching to Win11 I noticed a weird behaviour and haven't been able to find the cause. For some reason the F10 key seems to suddenly behave the same as the F10 followed by the Alt key with programs which have a menu/toolbar (Office, notepad++, etc) but the new notepad is affected differently. The menu isn't selected but F10+space is the same as Alt-Space under win10/7/xp, i.e it will open the main window control menu which will allow you to close the window.
This may be due to new accessibility stuff. Who knows.  It affects all programs in one way or another.

It would be handy to be able to just pull up a table of keys which indicated which windows components were intercepting a key to direct the search for how to disable the behaviour. Not sure how this could even be implemented. Is it even possible to separate out accesibility configurations from the main OS configuration, or even identify what a key is associated with?

### Supporting information

_No response_
Repository: pytorch
Issue: [Feature Request] Allow torch.Generator to be passed to torch.nn.init functions
Labels: module: nn,triaged

### 🚀 The feature, motivation and pitch

I think that would make a lot of sense.

### Alternatives

At the moment, before initializing a neural net I have to set the global random seed by calling torch.random.manual_seed(seed)

### Additional context

_No response_

cc @albanD @mruberry @jbschlosser @walterddr @kshitij12345