sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: angular
Issue: Add "contextual variables" to the new @defer
Labels: feature,area: core,feature: insufficient votes,core: defer

### Which @angular/* package(s) are relevant/related to the feature request?

core

### Description

The purpose of this feature request is to enhance the functionality of the newly proposed `@defer` syntax by introducing a contextual variable, referred to as `$resourceUrl`. This variable will be automatically populated with the import URL of the code that is marked to be deferred loaded.

The primary motivation for introducing the `$resourceUrl` contextual variable within the `@defer ` syntax is to streamline the management of service worker caches.
The presence of an auto-generated and easily accessible `$resourceUrl` mitigates the complexity of keeping a unique identifier refering to the unknown lazy loaded file for example in the indexedDB to identify if the service worker cache was already filled with the specific lazy loaded file.

This feature is expected to have a positive impact on the current workflow by reducing boilerplate code, minimizing errors related to manual URL handling, and standardizing the approach across the entire codebase.


### Proposed solution



In the component code something like the following would be possible

```TypeScript
// my-component.component.ts
@Component({
  ...
  template: `
    <!-- the `on` condition is just exemplary -->
    @defer(when isSWCached($resourceUrl); on viewport) {...}
  `
})
export class MyComponent {
  private messageChannel = new MessageChannel();
  
  constructor() {
	  navigator.serviceWorker.controller.postMessage({
		    type: 'INIT_PORT',
	  }, [this.messageChannel.port2]);
  
  }
  
  isSWCached(resourceUrl: string) {
	  return new Promise(resolve = >{
		  this.messageChannel.port1.onmessage = (event) => {
		    if (event.data.payload.id === resourceUrl) {
			    resolve(coerceBoolean(event.data.payload.isCached));
		    }
		  };
		  this.navigator.serviceWorker.controller.postMessage({
			    type: 'CHECK_CACHE',
			    payload: {
				    id: resourceUrl
			    }
		  });
	  };
  }
}
```

and the related service-worker.js could use the `caches` API directly to respond to the `postMessage`

```js
// service-worker.js
let _port;

// Listen to the CHECK_CACHE message
self.addEventListener('message', (event) => {
if (event.data && event.data.type === 'INIT_PORT') {
    _port = event.ports[0];
}
  
if (event.data && event.data.type === 'CHECK_CACHE') {
	caches.open(cacheName).then(async (cache) => {      
		const cacheResult = await cache.match(event.data.payload.id);
		_port.postMessage({
			payload: {
				isCached: cacheResult !== undefined
			}
		});
	})
  }
});
```


### Alternatives considered

The same can propably be achieved with using indexedDB and a custom unique identifier instead of the `$resourceUrl`, but would be much harder to implement in my opinion.
Repository: PowerToys
Issue: Resize (scale) a reparented crop-and-locked window
Labels: Idea-Enhancement,Needs-Triage,Product-CropAndLock

### Description of the new feature / enhancement

I want both capabilities at once - resize the window and still be able to interact with it.

### Scenario when this would be used?

Really just as stated, sometimes I want to be able to resize the content but keep the ability to interact with it.

### Supporting information

Sometimes I get functionality like this by using Remote Desktop (mstsc.exe) in full screen connection then resizing it to a small window (unlike the UWP client, the mstsc.exe remote display doesn't rescale with resized, it just stretches or shrinks).  It's basically like using < 100% display scaling, and that's essentially what I want from a crop & locked window: shrink it smaller while keeping everything desired in view (smaller) and interactable.
Repository: PowerToys
Issue: Remove Forced Always On Top from Crop & Locked Windows
Labels: Needs-Triage,Product-CropAndLock

### Description of the new feature / enhancement

Either mode of crop & lock causes the new window to be forced always on top.

### Scenario when this would be used?

This is not desirable to me.

### Supporting information

 in the event I wanted the window to be on top, Power Toys already provides that ability, so forcing it on without option seems weird.  Or it could be implemented as an option on the control menu of the crop/locked window if it's desirable to replicate the AOT PowerToy functionality here.
Repository: vscode
Issue: Variable in `window.title` for language id of active editor
Labels: feature-request,accessibility,titlebar

For accessibility purposes, it would be great if we were able to put the language id of the active editor in the window title.

Like with @meganrogge's https://github.com/microsoft/vscode/pull/190613, this window title variable would enable us to easily get critical information to Talon in real time to enable appropriate voice commands

Fwiw today we look for the file extension in the window title (eg `.ts` or `.py`) to determine language, but that is not completely reliable; eg it breaks for untitled documents

<!-- ⚠️⚠️ 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. -->
Repository: go
Issue: x/crypto: breaking api change in cryptobyte String.ReadASN1Integer since v0.4.0 leads to panic
Labels: NeedsInvestigation

<!--
Please answer these questions before submitting your issue. Thanks!
-->

### What version of Go are you using (`go version`)?

<pre>
$ go version
go version go1.21.3 darwin/arm64
</pre>

### Does this issue reproduce with the latest release?

Yes

### What operating system and processor architecture are you using (`go env`)?

<details><summary><code>go env</code> Output</summary><br><pre>
$ go env
...
GOARCH='arm64'
GOOS='darwin'
...
</pre></details>

### What did you do?

golang.org/x/crypto 0.4.0 introduced a breaking API change in the `AddASN1Int64()` method.
Previously, reflection was used to determine the underlying type of the provided `out` argument.
As of https://github.com/golang/crypto/commit/2c476679df9a5c6279ec05b48165f4bed48b792e - it instead uses type assertions.

This is a breaking change - while previously one could pass named types whose underlying types are integers,
that same code as of x/crypto >=0.4.0 will panic.

<!--
If possible, provide a recipe for reproducing the error.
A complete runnable program is good.
A link on go.dev/play is best.
-->

Reproduction:

https://go.dev/play/p/1__wSXq30mR

...

```
package main

import (
	"testing"

	"golang.org/x/crypto/cryptobyte"
)

type MyInt int64

func Test_ReadASN1Int64(t *testing.T) {
	const expectedVal = 1234

	b := cryptobyte.NewBuilder(nil)
	b.AddASN1Int64(expectedVal)
	buf, err := b.Bytes()
	if err != nil {
		t.Fatalf("failed serializing to buffer: %v", err)
	}

	var out MyInt // underlying type is int64

	t.Logf("deserializing type: %T", out)
	input := cryptobyte.String(buf)
	if !input.ReadASN1Integer(&out) {
		t.Errorf("deserializing integer failed")
	}
}
```


### What did you expect to see?
I expected code similar to the reproduction above to continue functioning with newer versions of x/crypto.
If this was not feasible, I would have at a minimum expected a release note describing the breaking change,
or to see it reflected in semantic versioning of the library.


### What did you see instead?
Working code began to panic upon upgrading x/crypto >= 0.4.0.
Repository: go
Issue: net/http: TestTransportFlushesRequestHeader failures with `close of closed channel`
Labels: NeedsInvestigation

```
#!watchflakes
post <- pkg == "net/http" && test == "TestTransportFlushesRequestHeader" && `close of closed channel`
```

Issue created automatically to collect these failures.

Example ([log](https://build.golang.org/log/afb3d256ebe25fd88ae41531468022fc8c8f6038)):

    --- FAIL: TestTransportFlushesRequestHeader (0.00s)
        --- FAIL: TestTransportFlushesRequestHeader/h2 (0.03s)
            clientserver_test.go:210: server log: http2: panic serving 127.0.0.1:35148: close of closed channel
                goroutine 10358 [running]:
                net/http.(*http2serverConn).runHandler.func1()
                	/workdir/go/src/net/http/h2_bundle.go:6104 +0x145
                panic({0x86b5e0, 0x9a8600})
                	/workdir/go/src/runtime/panic.go:884 +0x213
                net/http_test.testTransportFlushesRequestHeader.func1({0x600010ab?, 0x7a1969aaa5a5a59a?}, 0x40000000000000?)
                	/workdir/go/src/net/http/transport_test.go:4192 +0x1d
                net/http.HandlerFunc.ServeHTTP(0x0?, {0x9ac530?, 0xc00061a168?}, 0xc0002fd6a0?)
                	/workdir/go/src/net/http/server.go:2122 +0x2f
                net/http.serverHandler.ServeHTTP({0x8e42d6?}, {0x9ac530, 0xc00061a168}, 0xc000a78a00)
                	/workdir/go/src/net/http/server.go:2936 +0x316
                net/http.initALPNRequest.ServeHTTP({{0x9acba8?, 0xc002020ff0?}, 0xc000c9f880?, {0xc00032cf00?}}, {0x9ac530, 0xc00061a168}, 0xc000a78a00)
                	/workdir/go/src/net/http/server.go:3545 +0x245
                net/http.(*http2serverConn).runHandler(0xc000c08460?, 0xc0002fd7d0?, 0x6e6786?, 0xc0007d2bd0?)
                	/workdir/go/src/net/http/h2_bundle.go:6111 +0xc2
                created by net/http.(*http2serverConn).scheduleHandler
                	/workdir/go/src/net/http/h2_bundle.go:6046 +0x245
            transport_test.go:4205: stream error: stream ID 1; INTERNAL_ERROR; received from peer


— [watchflakes](https://go.dev/wiki/Watchflakes)
Repository: flutter
Issue: Running an Android (ADB) unit test suite is harder than expected
Labels: engine,P2,c: tech-debt,team-engine,triaged-engine

I'm working on https://github.com/flutter/engine/pull/47632.

Running (and re-running) an Android unit test suite is surprisingly hard. It would be nice to know if I'm holding it wrong, [documentation could be improved](https://github.com/flutter/flutter/wiki/Testing-the-engine), or this is just an area we could invest in more to make the ergonomics slightly less painful.

## What I want to do

Something like:

```shell
$ ninja -j1000 -C ../out/android_debug_unopt_arm64 flutter_shell_native_unittests
$ ../out/android_debug_unopt_arm64/flutter_shell_native_unittests
```

In a Bazel-like system it might be something like:

```shell
$ bazel test //shell/platform/android:flutter_shell_native_unittests
```

## What I tried to do

These tests require running on an Android device (or emulator), because they use:

```gn
source_set(...) {
  libs = [ "android" ]
}
```

The only way (IIRC) that works today in the engine repo is by using `./testing/run_tests.py`...

...which doesn't understand that I'm using `android_debug_unopt_arm64` and fails (with a confusing message):

```shell
$ ./testing/run_tests.py --type android

  File "/Users/matanl/Developer/engine/src/flutter/./testing/run_tests.py", line 181, in find_executable_path
    raise Exception('Executable %s does not exist!' % path)
Exception: Executable /Users/matanl/Developer/engine/src/out/host_debug_unopt/client_wrapper_glfw_unittests does not exist!
```

I can specify my target variant explicitly ... but then I get a mysterious ADB failure:

```shell
$ ./testing/run_tests.py --android-variant android_debug_unopt_arm64 --type android

Failed Command:

adb shell /data/local/tmp/flutter_shell_native_unittests

Exit Code: 139
```

I can keep plugging on this, but just wanted to share what I've tried so far.

_/cc @zanderso @jonahwilliams for the nerd snipe._
Repository: stable-diffusion-webui
Issue: [Feature Request]: Save the generation time information as PNG.
Labels: enhancement

### Is there an existing issue for this?

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

### What would your feature do ?

Saves the time information taken for generation as chunks in a PNG file.

It would be even better if you could turn this feature on/off in Settings.
Also,
If there is a textbox where you can enter any text, it will be convenient for you to leave a graphic card or a memo.

![time](https://github.com/AUTOMATIC1111/stable-diffusion-webui/assets/125081727/16f3e7d5-362f-4536-a3a8-231b61a53184)


### Proposed workflow

1. Go to Settings > Saveing images/grids
2. Check mark ON！　>  Saves the time information taken for generation as chunks in a PNG file.

3. Write a note in the TextBox
4. Check mark ON！　> Record the content entered in the TextBox to png


### Additional information

_No response_
Repository: ollama
Issue: `unexpected EOF` when running `ollama pull`
Labels: bug,networking

Occasionally while pulling a model the download may get stuck waiting for a part which experienced an error.
```bash
$ ollama run llama2:70b
pulling manifest
pulling 153664158022...  99% |█████████████████████████████████████████████████████████████████████████████████ | (38/39 GB, 619 kB/s) [24m57s:9m15s]
``` 

Server log:
```bash
2023/11/07 11:36:24 download.go:160: 153664158022 part 75 attempt 0 failed: unexpected EOF, retrying
```


Workaround is to stop and resume the download.
Repository: flutter
Issue: Script that uploads and generates android sdk for engine use should have dry run option 
Labels: P2,team-android,triaged-android

[android_sdk/create_cipd_packages](https://github.com/flutter/engine/blob/main/tools/android_sdk/create_cipd_packages.sh) script. 
Dry run option should provide the bundles that will be upload to CIPD without attempting to upload to cipd.
Repository: flutter
Issue: Script that uploads android sdk to cipd should fail on missing packages or failed copy commands 
Labels: P2,team-android,triaged-android

[android_sdk/create_cipd_packages](https://github.com/flutter/engine/blob/main/tools/android_sdk/create_cipd_packages.sh) script. 
This script when run will silently fail when a download fails and upload a malformed package with no error.  Modify the script to not upload if any download command fails. 

Related to https://github.com/flutter/flutter/issues/138021
Repository: flutter
Issue: Script that uploads and generates android sdk for engine use have a verbose mode 
Labels: P3,team-android,triaged-android

[android_sdk/create_cipd_packages](https://github.com/flutter/engine/blob/main/tools/android_sdk/create_cipd_packages.sh) script. 
This script does not print the commands it runs and suppresses helpful output while printing redundant licence information. Modify  script to have verbose mode used in debugging and do a pass on output to change the mix of output to be more helpful. 

Related to https://github.com/flutter/flutter/issues/138021 https://github.com/flutter/flutter/issues/138022
Repository: godot
Issue: Hebrew text and emoji aren't displayed when exporting to Web due to system font fallbacks being unavailable
Labels: platform:web,documentation,topic:gui

### Godot version

4.0.4.stable

### System information

Windows 11, Chrome latest

### Issue description

Added buttons and option button with some text in Hebrew
Everything works as expected When playing and also when exporting to Windows.
However when exporting to Web, and running in Chrome,  text becomes Gybrish


Windows
![image](https://github.com/godotengine/godot/assets/61090249/2b5da6fe-5220-4086-a338-c37e5a03304e)


Web
![image](https://github.com/godotengine/godot/assets/61090249/65d0829b-37cc-497e-b277-8444fa4e9d2a)


### Steps to reproduce

Adda button with Hebrew text, export to web project and serve, 

### Minimal reproduction project

.
Repository: angular
Issue: Extend the signature for @defer's when clause
Labels: feature,area: core,feature: insufficient votes,core: defer

### Which @angular/* package(s) are relevant/related to the feature request?

_No response_

### Description

Currently the `when` specifies an imperative condition as an expression that returns a boolean. 

But for more advanced usage of the `when` condition it should also be possible to use a function or method that returns an async value like a promise.

### Proposed solution

A possible signature for the following scenario

```
@defer(when condition()) {...}
```
 would look like this `condition(): boolean | Promise<boolean>`

### Alternatives considered

As @crisbeto pointed out, one can convert the promise to an observables and use the async pipe in the template
Repository: godot
Issue: Crash when posting semaphore after modifying a script at runtime
Labels: bug,topic:gdscript,topic:editor,crash

### Godot version

v4.2.beta5.official [4c96e9676]

### System information

Godot v4.2.beta5 - Windows 10.0.19045 - Vulkan (Forward+) - dedicated Radeon RX 580 Series (Advanced Micro Devices, Inc.; 31.0.21023.2010) - AMD Ryzen 5 3600 6-Core Processor (12 Threads)

### Issue description

When using a thread with a semaphore, the thread breaks when I run ```semaphore.post()``` after saving changes to any script at runtime. This often causes the running project to crash silently, but sometimes it keeps going with the Thread no longer working. I can reproduce the crash with the example code at https://docs.godotengine.org/en/latest/tutorials/performance/using_multiple_threads.html#semaphores.

The errors I get on 4.2 beta5 and 4.1.3 stable include:
- Game window closes with no error.
- No crash, but the thread function stops running.

And some errors only on 4.2, I suppose thanks to the new thread support in the debugger:
- ```mutex.lock()``` : Cannot call method 'lock' on a null value.
- ```semaphore = Semaphore.new()```: Cannot call method 'new' on a null value.
- Debugger catches an error, but game window closes so can't read stack trace.
- ```semaphore.wait()```: Internal script error! Opcode: 4 (please report).
    - Sometimes it's a different opcode.
- ```semaphore.wait()```: Bad address index.

### Steps to reproduce

1. Run the MRP
2. Click the Post button on screen, and notice the print statement in the console.
3. Without closing the game window, open main.gd in the editor and save the file.
4. On the game window, click the Post button again.

At this point it either crashes, or the print statement inside the threaded function no longer appears. Saving any script in the project will reproduce the bug. 

### Minimal reproduction project

The code is copied from the docs, with the addition of a print statement inside the loop.
[ThreadsScriptEditMRP.zip](https://github.com/godotengine/godot/files/13288760/ThreadsScriptEditMRP.zip)
Repository: storybook
Issue: [Bug]: CLI Updates for GH Discussions
Labels: cli

### Describe the bug

As we're moving towards providing support via GitHub Discussions instead of Discord, it is in our best interest to update some other sections of the codebase, including the CLI. For example [here](https://github.com/storybookjs/storybook/blob/next/code/lib/cli/src/initiate.ts) and [here](https://github.com/storybookjs/storybook/blob/next/code/lib/cli/src/automigrate/helpers/getMigrationSummary.ts).

To get this moving, we should either:
- Update the text to point to the discussions
- Tweak it to remove the mention of support to avoid users jumping onto Discord and start flooding general and / or support with questions

What needs to happen:
- Vet if there aren't any other places where we're using the same terminology or phrasing based on the ☝️ 

@vanessayuenn  and @joevaugh4n, let me know, and we'll take it from there.
Repository: next.js
Issue: customServer: false causes assets to 404 since 13.5.1
Labels: bug

### Link to the code that reproduces this issue

 https://github.com/besh/next-14-custom-server-asset-404

### To Reproduce

### Steps

1. 
```bash
yarn build
```

2.
```bash
yarn start
```

3. 
Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.


<img width="3008" alt="Screenshot 2023-11-07 at 2 21 58 PM" src="https://github.com/besh/next-14-custom-server-asset-404/assets/5420223/d88455c4-b8fa-472d-8694-1fcddc19b4d6">


Setting `next({ customServer: true })` resolves the 404s.

### Current vs. Expected behavior

Starting in next@13.5.1, setting `next({ customServer: false })` in a custom server.js file causes all `_next/static` assets to 404. I have verified that this error occurs in the latest canary (14.0.2-canary.18 at the time of writing).

Previous to `13.5.1`, `customServer` could be `false` and witness no 404s. 

### Verify canary release

- [X] I verified that the issue exists in the latest Next.js canary release

### Provide environment information

```bash
Operating System:
      Platform: darwin
      Arch: x64
      Version: Darwin Kernel Version 22.6.0: Wed Oct  4 21:25:26 PDT 2023; root:xnu-8796.141.3.701.17~4/RELEASE_X86_64
    Binaries:
      Node: 18.17.0
      npm: 9.6.7
      Yarn: 1.22.19
      pnpm: N/A
    Relevant Packages:
      next: 13.5.1
      eslint-config-next: 14.0.1
      react: 18.2.0
      react-dom: 18.2.0
      typescript: 5.2.2
    Next.js Config:
      output: N/A
```


### Which area(s) are affected? (Select all that apply)

Custom server, Next static assets

### Additional context

I tested my reproduction against versions of next@13.4.x and did not encounter any asset 404s. It wasn't until testing with next@13.5.1 that we encountered the 404s. I also tried newer Node versions (20.x) which did not make a difference.

Our custom server setup has used this config option for the past 3 years with no asset 404s. If this is a breaking change that requires us to remove this config option or set other options, we would appreciate guidance or documentation on the change! Thank you.
Repository: rust
Issue: Exponential compile time with invalid use of modifying-assignment operators
Labels: I-compiletime,T-compiler,C-bug

Found by fuzzing and probably only affects fuzzing

### Code

```rust
fn a() {
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1 += & 
    1
}
```

### Where it's slow

According to `-Z time-passes` the slowness is within `type_check_crate`.

`check_expr_coercible_to_type` is on the stack multiple times ([sample head](https://github.com/rust-lang/rust/files/13289875/Sample.of.rustc.txt))

### Regression

Regression in nightly-2023-04-30, maybe due to #110877?

<details>
<summary>Commits in range</summary>

```text
  commit[0] 2023-04-28UTC: Auto merge of #110901 - GuillaumeGomez:inlined-repr-rustdoc, r=notriddle
  commit[1] 2023-04-28UTC: Auto merge of #110967 - matthiaskrgr:rollup-vfbl7gm, r=matthiaskrgr
  commit[2] 2023-04-29UTC: Auto merge of #110643 - pietroalbini:pa-bump-stage0, r=Mark-Simulacrum
  commit[3] 2023-04-29UTC: Auto merge of #110978 - Dylan-DPC:rollup-xclzwax, r=Dylan-DPC
  commit[4] 2023-04-29UTC: Auto merge of #108106 - the8472:layout-opt, r=wesleywiser
  commit[5] 2023-04-29UTC: Auto merge of #110992 - bjorn3:sync_cg_clif-2023-04-29, r=bjorn3
  commit[6] 2023-04-29UTC: Auto merge of #110994 - matthiaskrgr:rollup-wv4u5yi, r=matthiaskrgr
  commit[7] 2023-04-29UTC: Auto merge of #110576 - jyn514:unify-test-args, r=ozkanonur
```

</details>

### Version

```text
rustc 1.75.0-nightly (fee5518cd 2023-11-05)
binary: rustc
commit-hash: fee5518cdd4435c60a57fe3bb734fc1a14abeb7a
commit-date: 2023-11-05
host: x86_64-apple-darwin
release: 1.75.0-nightly
LLVM version: 17.0.4
```