sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: go
Issue: all: add internal/asan and internal/msan packages
Labels: NeedsFix,compiler/runtime

There are a couple issues where having asan/msan enabled throw off tests for memory allocations, see https://github.com/golang/go/issues/64257 and https://github.com/golang/go/issues/64256.

Most tests already skip these memory allocation assertions when they detect that `race` is enabled, but such functionality is not exposed for asan and msan.

Here is one example of such test:

```go
if n := testing.AllocsPerRun(100, func() { Grow(s2, cap(s2)-len(s2)+1) }); n != 1 {
    errorf := t.Errorf
    if race.Enabled || testenv.OptimizationOff() {
        errorf = t.Logf // this allocates multiple times with race or msan enabled
    }
    errorf("Grow should allocate once when given insufficient capacity; allocated %v times", n)
}
```

One alternative is using the `asan` and `msan` build tags to skip certain tests, but that does not work in the middle of a test, only for entire files.

There is `runtime.msanenabled`, `runtime.asanenabled`, `syscall.asanenabled` we could use, but they are private to their respective packages.

It is worth noting that syscall and runtime duplicate some code related to asan:
- syscall has asanenabled, asanRead, asanWrite that basically call into the runtime.
- runtime has asanenabled as well

I propose we create `internal/asan` and `internal/msan` packages akin to `internal/race`. Then syscall and runtime would call `internal/asan.Enabled` and syscall could use `ASanRead`, `ASanWrite` as well, without having this logic duplicated.

The tests can also use `internal/asan.Enabled` to check if they should skip tests that allocate memory, which most tests already do currently by checking `race.Enabled`. We can also use these inside `testenv.SkipIfOptimizationOff/testenv.OptimizationOff` to make this process more seamless.

Here is the proposed apis for these new internal packages:

## internal/asan

```go
//go:build asan

package asan

import (
	"unsafe"
)

const Enabled = true

func Read(addr unsafe.Pointer, len int)
func Write(addr unsafe.Pointer, len int)
```

> The !asan version would have stubs for these functions.

## internal/msan

The only place that uses msan currently is the runtime, but having access to a msan.Enabled would be useful in tests as well and would make a good trio with `internal/asan` and `internal/race`. Other packages might be able to use the exported functions more easily as well.

The proposed api for internal/msan would then be:

```go
//go:build msan

package msan

import (
	"unsafe"
)

const Enabled = true

func Read(addr unsafe.Pointer, sz uintptr)
func Write(addr unsafe.Pointer, sz uintptr)
func Malloc(addr unsafe.Pointer, sz uintptr)
func Free(addr unsafe.Pointer, sz uintptr)
func Move(dst, src unsafe.Pointer, sz uintptr)
```

> The !msan version would have stubs for these functions.
Repository: vscode
Issue: Unified URL line number context menu
Labels: feature-request,continue-working-on

<!-- ⚠️⚠️ 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. -->
![Screenshot of the Share submenu](https://github.com/microsoft/vscode/assets/90388353/15df732c-2c61-4d14-ac3e-ae2639ba092f)
![Screenshot of the Open on Remote (Web) submenu](https://github.com/microsoft/vscode/assets/90388353/e2511965-141c-41e9-87a2-c91e872d529e)

When right clicking on a line number there's the following menu:
```
Copy vscode.dev link
Share
	Copy Remote FIle URL
	Copy Remote File URL From...
	Copy Remote Commit URL
Open Changes
	...
Open Remote
	Open File on Remote
	Open File on Remote From...
	Open Commit on Remote
```
I feel like everything other than `Open Changes` could be more unified. I don't know how exactly, I just noticed this and found it kind of annoying to navigate when copying a lot of file URLs.
Repository: angular
Issue: Service Worker 504 Gateway Timeout for external resources
Labels: area: service-worker

### Which @angular/* package(s) are the source of the bug?

service-worker

### Is this a regression?

No

### Description

The fetch call for external resources, such as analytics scripts, ad manager scripts or styles will always fail when invoked after the service worker has been initialized. It appears that this is true for all opaque responses, where one can't control the CORS configuration.

I've deployed a fresh Angular 17 app generated with the CLI on Cloud Run. The only modification I've done is add the Google Analytics script to **index.html**. Note that there is nothing special about this script, it will fail the same way for any other external resource.
Repo that's in-sync with the deployed app: https://github.com/zerefel/angular-sw-fetch

## Reproduction steps
- Load the app for the first time or hit **Ctrl + Shift + R** -> The analytics script will be loaded successfully.
- Refresh the page (**Ctrl + R**) -> The analytics script can't be loaded.

I've been testing with various ngsw-config.json setups, tried to configure it with dataGroups, I also went through pretty much every single related issue, read the service worker documentation multiple times, nothing seems to help, so I can only assume this is a bug.

## Expected behavior
The service worker manages to load the resources, or at least give a meaningful error message.


### Please provide a link to a minimal reproduction of the bug

https://angular-sw-test-ccqkuvfrra-nw.a.run.app

### Please provide the exception or error you saw

```true
TypeError: Failed to fetch
    at Driver.safeFetch (ngsw-worker.js:1832:33)
```


### Please provide the environment you discovered this bug in (run `ng version`)

```true
Angular CLI: 17.0.6
Node: 20.9.0
Package Manager: npm 10.1.0
OS: linux x64

Angular: 17.0.6
... animations, cli, common, compiler, compiler-cli, core, forms
... platform-browser, platform-browser-dynamic, platform-server
... router, service-worker, ssr

Package                         Version
---------------------------------------------------------
@angular-devkit/architect       0.1700.6
@angular-devkit/build-angular   17.0.6
@angular-devkit/core            17.0.6
@angular-devkit/schematics      17.0.6
@schematics/angular             17.0.6
rxjs                            7.8.1
typescript                      5.2.2
zone.js                         0.14.2
```


### Anything else?

Due to the nature of some dependencies, which request an arbitrary number of scripts of their own, (e.g. ad manager scripts), it is not viable to list every single URL in the dataGroups config, as they may not be known or could dynamically change.
Repository: PowerToys
Issue: Clean uninstaller
Labels: Area-Setup/Install,Needs-Triage,Needs-Team-Response

### Description of the new feature / enhancement

I recently had an issue that required me to do a thorough uninstall (a simple uninstall did not resolve the issue) of Powertoys to resolve (see issue [here](https://github.com/microsoft/PowerToys/issues/30183)). 

Would be nice to be able to do a clean uninstall via an uninstaller to make sure the uninstall is as thorough as possible.

### Scenario when this would be used?

When needing to do a clean re-install of Powertoys

### Supporting information

_No response_
Repository: godot
Issue: CharacterBody2D not using real velocity when leaving floor
Labels: topic:physics,needs testing,topic:2d

### Tested versions

v4.2.stable.official [46dc27791]

### System information

Godot v4.2.stable - Windows 10.0.19045 - Vulkan (Forward+) - dedicated NVIDIA GeForce GTX 1060 6GB (NVIDIA; 31.0.15.4617) - Intel(R) Core(TM) i5-7500 CPU @ 3.40GHz (4 Threads)

### Issue description

When a grounded CharacterBody2D leaves a sloped floor, the "fake" velocity is used, meaning it doesn't account for the vertical velocity (which is included in CharacterBody2D.get_real_velocity).

Example clip:

https://github.com/godotengine/godot/assets/26576399/000d1be8-be41-4cd1-9c77-756d64b1d37e



### Steps to reproduce

Move a CharacterBody2D down a sloped floor that eventually ends. Apply gravity. Characterbody2D leaves floor with no vertical velocity.

Demo instructions: character should respawn automatically, but can manually respawn with "r". 
Note motion of character when it leaves the slope.

### Minimal reproduction project (MRP)

[bugDemo.zip](https://github.com/godotengine/godot/files/13606687/bugDemo.zip)
Repository: flutter
Issue: Warn / throw when requested font assets are missing
Labels: framework,a: assets,a: error message,has reproducible steps,P2,team-framework,triaged-framework,found in release: 3.16,found in release: 3.18

The use case here is to help with debugging missing fonts used at runtime. For example, a developer might attempt to reduce the size of the app bundle by incrementally stripping out font assets. But other than screenshot tests or having an extremely keen eye for typefaces, it seems like it isn't possible for them to identify that they have made a mistake by stripping out a font that is actually used at runtime.

Perhaps we could have warnings for this enabled by default in debug mode, and also provide a toggle for users to make these warnings throw an error.

### Is there an existing issue for this?

- [X] I have searched the [existing issues](https://github.com/flutter/flutter/issues)
- [X] I have read the [guide to filing a bug](https://flutter.dev/docs/resources/bug-reports)

### Steps to reproduce

Run the code snippet below.

### Expected results

The framework should inform the developer that the requested font is missing.

### Actual results

When running the code snippet, no warnings or errors are printed in the console.

### Code sample

<details><summary>Code sample</summary>

```dart
import 'package:flutter/widgets.dart';

void main() {
  runApp(
    Container(
      color: const Color(0xFFFFFFFF),
      child: const Directionality(
        textDirection: TextDirection.ltr,
        child: Text(
          'Hello',
          style: TextStyle(fontFamily: 'does not exist'),
        ),
      ),
    ),
  );
}
```

</details>


### Flutter Doctor output

DartPad Based on Flutter 3.16.2 Dart SDK 3.2.2
Repository: godot
Issue: Scene corruption after forced reboot on Linux
Labels: bug,topic:core,confirmed

### Tested versions

v4.2.stable.official [46dc27791]

### System information

Ubuntu 22.04 - v4.2.stable.official [46dc27791]

### Issue description

Believe I did a `sudo reboot now` and was able to trigger a non-proper flushing of the file causing a corruption

```text
scene/resources/resource_format_text.cpp:284 - res://scenes/game/Bullet.tscn:10 - Parse Error: 
  Failed loading resource: res://scenes/game/Bullet.tscn. Make sure resources have been imported by opening the project in the editor at least once.
  Failed to instantiate scene state of "res://scenes/game/Bullet.tscn", node count is 0. Make sure the PackedScene resource is valid.
  Failed to instantiate scene state of "res://scenes/game/Bullet.tscn", node count is 0. Make sure the PackedScene resource is valid.
  Failed to instantiate scene state of "res://scenes/game/Bullet.tscn", node count is 0. Make sure the PackedScene resource is valid.
  ```
 
**Bullet.tscn**
 ```tscn
 [gd_scene load_steps=4 format=3 uid="uid://bpw08h6qjtf80"]

[ext_resource type="Texture2D" uid="uid://87j7ldt0dsn7" path="res://icon.svg" id="1_rqlw1"]
[ext_resource type="Script" path="res://scenes/game/Bullet.gd" id="1_v4orp"]

[sub_resource type="RectangleShape2D" id="RectangleShape2D_21qps"]
size = Vector2(32, 32)

[node name="Area2D" type="Area2D"]
script = ExtResource("1_v4orp")

[node name="Sprite2D" type="Sprite2D" parent="."]
scale = Vector2(0.25, 0.25)
texture = ExtResource("1_rqlw1")

[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
texture_filter = 1
shape = SubResource("RectangleShape2D_21qps")

[connection signal="body_entered" from="." to="." method="_on_body_entered"]
```

### Steps to reproduce

Probably have the script opened in a potentially unsaved state and force a reboot...

### Minimal reproduction project (MRP)

N/A
Repository: terminal
Issue: Attempt to configure "Terminal Chat" on second machine results in invalid Azure OpenAI endpoint error.
Labels: Issue-Bug,Product-Terminal,Needs-Tag-Fix,Area-Chat

### Windows Terminal version

1.20.3401.0

### Windows build number

22635.2841

### Other Software

_No response_

### Steps to reproduce

1. I have "Terminal Chat" successfully configured on one machine already.
2. Open up Terminal, go to Settings > Terminal Chat, add the endpoint URL and Key 2.
3. Save Settings and close Terminal.
4. Reopen Terminal and go to Terminal Chat.
5. Attempt to enter prompt.
6. Be greeted with a message saying the endpoint I provided is not a valid Azure OpenAI endpoint.

![image](https://github.com/microsoft/terminal/assets/123279/4e099d00-0ad3-45cc-856e-35b44bf4528f)
![image](https://github.com/microsoft/terminal/assets/123279/37a8e95d-0a1f-4762-a7f4-40ddc78e0391)




### Expected Behavior

![image](https://github.com/microsoft/terminal/assets/123279/ec10fdd6-e8c3-4f97-b58a-97140691bcdd)

I was expecting similar results as this screenshot shows, where the Terminal is _actually_ connecting to, and interacting with, the LLM.

### Actual Behavior

Received the "Not a valid endpoint" error message
Repository: vscode
Issue: Cannot Save Jupyter Notebook on SSH Disconnect
Labels: bug,notebook-remote

### Applies To

- [X] Notebooks (.ipynb files)

### What happened?

When the connection to my remote development server disconnects, I sometimes have unsaved changes that need to be saved locally before reloading the window so I don't lose work. However, I can't seem to save locally. File > Save As produces an error: `Failed to save '<>.ipynb': NO provider registered for view type: 'jupyter-notebook'`

The closest related issue I could find was [this](https://github.com/coder/code-server/issues/4777) which is related to code server and requires the user to apparently open a folder before attempting to save. If my issue is similar, it may indicate that the jupyter-notebook viewer needs the local folder I'm saving to already open in the Workspace, which isn't good because I can't add the local location.

I really just need a way to export files when the SSH session crashes and the window needs reloading. For now I have to copy all the cells into a new local file and hope that diff can help me sort out the unsaved changes...

**UPDATE**:
On checking extension version, returning to the notebook's tab showed that the Jupyter extension was no longer active (hence the command viewOutput not found below), so I had to open the file as text and use that to save a local copy. Maybe my problem is that the jupyter extension gets unloaded when the SSH session crashes so I can't even save files anymore. That's an issue for ensuring work can be saved despite (possibly unstable) remote connections...

### VS Code Version

1.83.0

### Jupyter Extension Version

v2023.9.1102792234

### Jupyter logs

```shell
command 'jupyter.viewOutput' not found
```


### Coding Language and Runtime Version

Python

### Language Extension Version (if applicable)

_No response_

### Anaconda Version (if applicable)

_No response_

### Running Jupyter locally or remotely?

Local
Repository: vscode
Issue: Sometimes opening a new notebook doesn't focus it
Labels: bug,notebook

Ref https://github.com/microsoft/vscode-jupyter/issues/13765

## Environment data

Jupyter
v2023.6.1001801100
Pre-Release

Version: 1.80.0-insider (user setup)
Commit: 45b31e9a872da8cc3cc8fff41c1eeb2063be04b7
Date: 2023-06-27T05:33:23.513Z
Electron: 22.3.14
ElectronBuildId: 21893604
Chromium: 108.0.5359.215
Node.js: 16.17.1
V8: 10.8.168.25-electron.0
OS: Windows_NT x64 10.0.22621

## Expected behaviour

XXX

## Actual behaviour

XXX

## Steps to reproduce:

Run `Create: New Jupyter Notebook`

Sometimes when doing this it does not focus the notebook, it has happened 3 times out of around 10 times for me. This latest time shows that the search activity bar icon is focused:

![image](https://github.com/microsoft/vscode-jupyter/assets/2193314/ae08c4b4-7f08-4b8e-8a20-783ad09eaa04)


[**NOTE**: Self-contained, minimal reproducing code samples are **extremely** helpful and will expedite addressing your issue]

1. XXX

<!--
Note: If you think a GIF of what is happening would be helpful, consider tools like https://www.cockos.com/licecap/, https://github.com/phw/peek or https://www.screentogif.com/ .
-->

## Logs

<details>

<summary>Output for <code>Jupyter</code> in the <code>Output</code> panel (<code>View</code>→<code>Output</code>, change the drop-down the upper-right of the <code>Output</code> panel to <code>Jupyter</code>)
</summary>

<p>

```
XXX
```

</p>
</details>
Repository: vscode
Issue: Raw file contains image data even if it is not shown in the notebook
Labels: bug,notebook-markdown

Testing microsoft/vscode-jupyter#11463

- Open an ipynb notebook
- Take a screenshot, paste into a markdown cell
- Ctrl+Enter to turn the markdown cell into preview
- Double click the markdown cell to continue editing the cell, then  delete the attachment link from the markdown cell
🐛 Save the document. Then right click on the editor title bar, run Reopen Editor With ... to open in a text editor, please make sure the image attachment data is not in the file.

![image](https://user-images.githubusercontent.com/10746682/192707846-412a84c4-bd84-4221-868d-20f6ced92b55.png)
Repository: vscode
Issue: Undo command does not restore deleted cell
Labels: bug,notebook-commands,notebook-undo-redo

<!-- Please search existing issues to avoid creating duplicates. -->

## Environment data

-   VS Code version: 1.73.1
-   Jupyter Extension version v2022.9.1303220346
-   Python Extension version (available under the Extensions sidebar): 3.9.7
-   OS (Windows | Mac | Linux distro) and version: Windows 10 homes 64-bit
-   Jupyter server running: Local


The undo command 'Z' does not work. I am making sure that no cell is active and that the notebook is selected, but nothing happens.

![gg](https://user-images.githubusercontent.com/10508286/202861100-8a11edd5-d4f0-4e31-92df-d581cda5df5e.JPG)
Repository: vscode
Issue: Find + Replace not indexing properly - VSCode / Jupyter Notebook Extension
Labels: bug

<!-- Please search existing issues to avoid creating duplicates. -->

## Environment data

-   VS Code version:  1.76.1 (Universal)
-   Jupyter Extension version (available under the Extensions sidebar): v2023.2.1200692131
-   Python Extension version (available under the Extensions sidebar): v2023.4.1
-   OS (Windows | Mac | Linux distro) and version: 12.6.2 (21G320)
-   Python and/or Anaconda version: 3.10.5
-   Type of virtual environment used (N/A | venv | virtualenv | conda | ...): N/A
-   Jupyter server running: Local 

## Expected behaviour

Find + Replace:
Replace value then index to next value in total matches (i.e. if replaced 3 of 14, index to 4th match) and scroll to 4th index.

## Actual behaviour

Replace value then index to next value in total matches (i.e. if replaced 3 of 14, index to 4th match) but does not scroll to 4th index. Have to manually index to next match then backwards to see current match.

## Steps to reproduce:

[**NOTE**: Self-contained, minimal reproducing code samples are **extremely** helpful and will expedite addressing your issue]

1. Replace value then index to next value in total matches (i.e. if replaced 3 of 14, index to 4th match) but does not scroll to 4th index. Have to manually index to next match then backwards to see current match.

<!--
Note: If you think a GIF of what is happening would be helpful, consider tools like https://www.cockos.com/licecap/, https://github.com/phw/peek or https://www.screentogif.com/ .
-->

## Logs

<details>

<summary>Output for <code>Jupyter</code> in the <code>Output</code> panel (<code>View</code>→<code>Output</code>, change the drop-down the upper-right of the <code>Output</code> panel to <code>Jupyter</code>)
</summary>

<p>

```
XXX
```

</p>
</details>
Repository: vscode
Issue: The functions for "match the whole word" and "match case sensitive" fail
Labels: bug,notebook-find

### Applies To

- [X] Notebooks (.ipynb files)
- [ ] Interactive Window and\/or Cell Scripts (.py files with \#%% markers)

### What happened?

Below is an example for "match case sensitive", where I first pressed `Alt+C`, and then, by selecting `x1` , typed`Shift+Ctrl+L` to match all. But it still matches `X1` (which should only match `x1` with lowest case). 
To show that this is not because that I am already in "case sensitive mode" before pressing `Alt+C`, I pressed `Alt+C` again, still, `X1` is being matched. 
Also from the search panel on the top right, it shows that the icon "Aa" is not activated when I pressed `Alt+C`.  (Though I can manualy click that icon, but nothing changes but the icon will be highlighted, as if it is activated, but still did not do the right matching)
The same issue happens to `Alt+W` (match the whole word) too. 

![Jupyter](https://user-images.githubusercontent.com/22186947/231808742-2288516c-137b-4568-b75b-f745a234d7bd.gif)

This only happens in Jupyter notebook. For example, in normal plain text editor, `Alt+C` and `Alt+W` works normally as shown below.

![text](https://user-images.githubusercontent.com/22186947/231810849-c139d849-743c-4b9e-9bbd-85301ae915fe.gif)


### VS Code Version

Version: 1.78.0-insider (user setup) Commit: 7f03ec6f7a48791d8027761b22773b454fc52478 Date: 2023-04-10T15:38:56.561Z Electron: 22.4.4 Chromium: 108.0.5359.215 Node.js: 16.17.1 V8: 10.8.168.25-electron.0 OS: Windows_NT x64 10.0.19045 Sandboxed: Yes

### Jupyter Extension Version

v2023.4.1001051011

### Jupyter logs

```shell
There is no output in Jupyter Server Console when pressing any of the key above.
```


### Coding Language and Runtime Version

_No response_

### Language Extension Version (if applicable)

_No response_

### Anaconda Version (if applicable)

_No response_

### Running Jupyter locally or remotely?

Local