sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: go
Issue: net/http: context deadline can cause surprising errors
Labels: Unfortunate,NeedsInvestigation

### Go version

go1.21.4

### What operating system and processor architecture are you using (`go env`)?

```shell
GO111MODULE=''
GOARCH='arm64'
GOBIN=''
GOCACHE='/Users/jhumphries/Library/Caches/go-build'
GOENV='/Users/jhumphries/Library/Application Support/go/env'
GOEXE=''
GOEXPERIMENT=''
GOFLAGS=''
GOHOSTARCH='arm64'
GOHOSTOS='darwin'
GOINSECURE=''
GOMODCACHE='/Users/jhumphries/go/pkg/mod'
GONOPROXY='buf.build/gen/go,github.com/bufbuild/buf-lang'
GONOSUMDB='buf.build/gen/go,github.com/bufbuild/buf-lang'
GOOS='darwin'
GOPATH='/Users/jhumphries/go'
GOPRIVATE='buf.build/gen/go,github.com/bufbuild/buf-lang'
GOPROXY='https://proxy.golang.org,direct'
GOROOT='/opt/homebrew/Cellar/go/1.21.4/libexec'
GOSUMDB='sum.golang.org'
GOTMPDIR=''
GOTOOLCHAIN='auto'
GOTOOLDIR='/opt/homebrew/Cellar/go/1.21.4/libexec/pkg/tool/darwin_arm64'
GOVCS=''
GOVERSION='go1.21.4'
GCCGO='gccgo'
AR='ar'
CC='cc'
CXX='c++'
CGO_ENABLED='1'
GOMOD='/Users/jhumphries/src/connect-go/internal/conformance/go.mod'
GOWORK=''
CGO_CFLAGS='-O2 -g'
CGO_CPPFLAGS=''
CGO_CXXFLAGS='-O2 -g'
CGO_FFLAGS='-O2 -g'
CGO_LDFLAGS='-O2 -g'
PKG_CONFIG='pkg-config'
GOGCCFLAGS='-fPIC -arch arm64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -ffile-prefix-map=/var/folders/vy/ws2js8yx4n581x_g8m_cs9jw0000gn/T/go-build1785425850=/tmp/go-build -gno-record-gcc-switches -fno-common'
```


### What did you do?

Used a context with a timeout when using `http.Client.Do`

### What did you expect to see?

I would expect any error returned from `Do` that was caused by the deadline elapsing be identifiable using `errors.Is(err, context.DeadlineExceed)`.

### What did you see instead?

There are certain places where dialing can fail due to the deadline that return an underlying error of type `internal/poll.DeadlineExceededError`. Unlike `net.errTimeout`, this types does _not_ implement the `Is(error) bool` method to consider itself equivalent to `context.DeadlineExceeded`.

So callers must check against both `context.DeadlineExceeded` **and** `os.ErrDeadlineExceeded` in order to determine if the returned error was due to the context deadline.
Repository: deno
Issue: [Deno KV] In-memory backend
Labels: suggestion,ext/kv

ATM the local KV instances are always backed by an SQLite database.

There would be at least two use-cases where having a memory only backend would be interesting:
- Memcached/Redis alternative, this has the advantage that you get no dependencies and possible extra performance from the in-process memory. Plus, you get a uniform API for working with ephemeral or persistent storages.
- An interesting and possible more performant way to implement Web worker concurrency, this would be implemented with the semantics of the KV atomic operations.
Repository: electron
Issue: [Feature Request]: Enable preloads in iframes without node integration
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

https://github.com/electron/electron/pull/16425 allows preloads for iframes, but only if `nodeIntegrationInSubFrames` is set to true. We would like to keep node integration off but allow us to run preloads in iframes.

### Proposed Solution

create a new flag `preloadInSubFrames` to allow running just the preload without node integration

### Alternatives Considered

use https://www.electronjs.org/docs/latest/api/web-frame-main to get a handle on web contents and inject through javascript. However does not have nice things like context isolation and exposeInMainWorld

### Additional Information

_No response_
Repository: vscode
Issue: SIGSEGV: node::inspector::InspectorIo::Start
Labels: upstream,freeze-slow-crash-leak,extension-host,nodejs

Build: https://dev.azure.com/monacotools/a6d41577-0fa3-498e-af22-257312ff0545/_build/results?buildId=246908
Changes: https://github.com/Microsoft/vscode/compare/858b389...94a83ff

```
Extension host (LocalProcess pid: 3588) is unresponsive.
Extension host (LocalProcess pid: 3588) is responsive.
[main 2023-11-29T18:19:13.098Z] Extension host with pid 3588 exited with code: 11, signal: unknown.
[main 2023-11-29T18:19:13.100Z] [UtilityProcess id: 1, type: extensionHost, pid: 3588]: crashed with code 11 and reason 'crashed'
Asking native host service to exit with code 11.
```
Repository: neovim
Issue: Vim syntax highlighting broken after long line
Labels: bug-vim,syntax,needs:vim-patch

### Problem

When a line has length > `synmaxcol`, and it's set to `nowrap`, the syntax highlighting of the next lines becomes wrong:
![image](https://github.com/neovim/neovim/assets/4710875/fe1fae04-e12f-45fe-aad3-a6cf836e8f5b)



### Steps to reproduce

1. Generate a file `test.py` with following content:
```python
a = "111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111"
b = 2
c = 3
d = 4
```
2. `nvim --clean test.py`
3. `set nowrap`
4. `set synmaxcol=220`


### Expected behavior

The highlighting not messed up.

### Neovim version (nvim -v)

v0.10.0-dev-64b53b7

### Vim (not Nvim) behaves the same?

yes, Vi IMproved 9.0 (2022 Jun 28, compiled Nov 22 2023 00:00:00)

### Operating system/version

fedora 39

### Terminal name/version

wezterm nightly 20231127_013355_05ae4e21-0

### $TERM environment variable

xterm-256color

### Installation

nvim-linux64.tar.gz from github release page
Repository: tensorflow
Issue: MemoryError: std::bad_alloc when calling tf.squeeze with a floating tensor axis
Labels: awaiting review,stat:awaiting tensorflower,type:bug,comp:ops,TF2.14

### Issue type

Bug

### Have you reproduced the bug with TensorFlow Nightly?

Yes

### Source

source

### TensorFlow version

tf 2.14.0, tf-nightly

### Custom code

Yes

### OS platform and distribution

_No response_

### Mobile device

_No response_

### Python version

_No response_

### Bazel version

_No response_

### GCC/compiler version

_No response_

### CUDA/cuDNN version

_No response_

### GPU model and memory

_No response_

### Current behavior?

When calling tf.squeeze with axis to be floating tensor, it will raise memory error. MemoryError looks dangerous to me, a proper input argument handling may be better.


### Standalone code to reproduce the issue

```shell
import tensorflow as tf
input = tf.constant([1,2,3], dtype='float32')
axis = tf.constant(1.0, dtype='float32')
out = tf.squeeze(input,axis)
```


### Relevant log output

```shell
/usr/local/lib/python3.10/dist-packages/tensorflow/python/ops/gen_array_ops.py in squeeze(input, axis, name)
  10614   if tld.is_eager:
  10615     try:
> 10616       _result = pywrap_tfe.TFE_Py_FastPathExecute(
  10617         _ctx, "Squeeze", name, input, "squeeze_dims", axis)
  10618       return _result

MemoryError: std::bad_alloc
```
Repository: rust
Issue: make std docs much more pedantically clear about primitive operators
Labels: A-docs,T-libs

### Location

*vaguely gestures to std's docs in general*

### Summary

Many operator/trait impls in std are undocumented. Most of the time this is basically fine, but for some things this is a lost opportunity to mention a trait's subtle/important semantics. For maintenance/noise reasons, these docs should be fairly short and prefer linking more verbose/detailed unified documentation on the subject in interest.

e.g. `See the the docs on [integer overflow](some-link-to-central-docs)` or something similarly brief.

To get started, the primitive types and their operators are great candidates. They don't at all mention overflow semantics, and it's up to the user to figure it out themselves by googling for rust overflow. Similarly for the flavours of shifts/division/modulo.

The reference [*does* have a great page for std to link way more aggressively](
https://doc.rust-lang.org/stable/reference/expressions/operator-expr.html), although it could merit some more details, more accessible language, more examples, etc. There's also [these docs in TRPL](https://doc.rust-lang.org/book/ch03-02-data-types.html).

Otherwise if the reference wants to be kept at its current level of detail, we could repurpose the otherwise empty module docs in [num](https://doc.rust-lang.org/core/num/index.html) or maybe [ops](https://doc.rust-lang.org/core/ops/index.html).

I'm mildly inclined to have docs in num/ops because that feels like the more appropriate place to take the time to enumerate all the std APIs that *do* exist to fill in all the different approaches to overflow (panic, wrap, saturate, Option, ...), shift (logical, arithmetic, ...), div/rem (rounding direction, sign handling, ...), casts (truncate, zero-extend, sign-extend, panic, Option, ...). If we do follow this path then it should cross-link the reference and vice-versa. 

I especially would love to see more time spent luxuriating in examples that really poke at the different corner cases in these solutions and how they differ in behaviour, which is often the easiest way to make everyone 100% confident we agree on which things have which behaviours.

I will happily mentor/review all work on this issue.
Repository: flutter
Issue: Create monitoring for Apple code signing quota
Labels: P1,from: postmortem,team-release

We should be tracking our quota use so we can attribute failures to capacity issues. This is follow up from 3.16 as there were some issues we suspect were related to quota issues.

We should update Cocoon to query the Notary API, and write the metrics to BigQuery. This is similar to what [GitHubRateLimit](https://cs.opensource.google/flutter/cocoon/+/main:app_dart/lib/src/request_handlers/github_rate_limit_status.dart) does.
Repository: flutter
Issue: [Impeller] Handle non-affine transforms correctly in the new blur.
Labels: engine,P2,e: impeller,team-engine,triaged-engine

This is how Skia renders blurs with non-affine transforms.

Skia fiddle:
![image](https://github.com/flutter/flutter/assets/919017/0cad3ef7-eb46-4c19-8d94-21ff4c8e7a56)

https://fiddle.skia.org/c/b6c65ddb70ffbef819834e8cf6bbad16

The way we'll end up rendering this today in Impeller is different, the blur effect will be completely uniform across the image and not reflect the transform fully.

We could do this without having to change the `RenderToSnapshot` protocol/behaviors. At the beginning of the blur render code before grabbing the snapshot, separate the Entity transform into two parts -- one with just the derived scale (no skew or projection, etc) and another with everything else. Then, just pass the scale-only transform to `GetSnapshot` and work with it until the end and incorporate the remainder part of the Entity's transform at the end of the blur.

This is an easier trick to do in the new blur since it's all combined into one `FilterContents`, and would eliminate the need for the complicated inverse UV mapping trickery.
Repository: TypeScript
Issue: Formatter: indent second operand of intersection operator on next line one indent more
Labels: Suggestion,Domain: Formatter,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 use "vscode.typescript-language-features" as my default JS/TS formatter, and when formatting long lines, the indentation could be improved.

As an example, this is the resulting code after "vscode.typescript-language-features":

```js
const Label = React.forwardRef<
  React.ElementRef<typeof LabelPrimitive.Root>,
  React.ComponentPropsWithoutRef<typeof LabelPrimitive.Root> &
  VariantProps<typeof labelVariants> // <= This line isn't sufficiently indented.
>(({ className, ...props }, ref) => (
  <LabelPrimitive.Root
    className={cn(labelVariants(), className)}
    ref={ref}
    {...props}
  />
));
```

Please note that the 4th line isn't indented deeper.
What would be visually clearer would be:

```js
const Label = React.forwardRef<
  React.ElementRef<typeof LabelPrimitive.Root>,
  React.ComponentPropsWithoutRef<typeof LabelPrimitive.Root> &
    VariantProps<typeof labelVariants> // <= This line indented deeper.
>(({ className, ...props }, ref) => (
  <LabelPrimitive.Root
    className={cn(labelVariants(), className)}
    ref={ref}
    {...props}
  />
));
```

Is there a way to wrap them in a way that the result looks like the second snippet?
Repository: pytorch
Issue: Add head_mask for transformers
Labels: module: nn,triaged

### 🚀 The feature, motivation and pitch

I am wondering if we can also have the head_mask, which can manually alter the attention_weights after the softmax
[From Huggingface](https://github.com/huggingface/transformers/blob/main/src/transformers/models/roberta/modeling_roberta.py#L272C1-L274C58)

### Alternatives

_No response_

### Additional context

_No response_

cc @albanD @mruberry @jbschlosser @walterddr @mikaylagawarecki @bhosmer @cpuhrsch @erichan1 @drisspg
Repository: PowerToys
Issue: FancyZones restores child window position to main window position
Labels: Issue-Bug,Product-FancyZones,Needs-Triage,Needs-Team-Response

### Microsoft PowerToys version

0.75.1

### Installation method

Microsoft Store

### Running as admin

No

### Area(s) with issue?

FancyZones

### Steps to reproduce

- Tick "Move newly created windows to their last known zone"
- Untick "Allow child windows snapping"
- Start Visual Studio 2022
- Snap main Visual Studio window to a zone
- Drag a tool window outside the main Visual Studio window
- Close Visual Studio
- Start Visual Studio

The detached tool window is placed over the main window by fancy zones

### ✔️ Expected Behavior

With "Allow child windows snapping" off, FancyZones should not reposition child windows.

With "Allow child windows snapping" on, FancyZones should remember child window positions and correctly restore them on program launch.

### ❌ Actual Behavior

The child window position is always restored to the main window position, effectively covering the whole main window on program launch.

### Other Software

Visual Studio 2022
(probably all Apps featuring child windows)
Repository: godot
Issue: Closing console wrapper closes external apps
Labels: bug,platform:windows,topic:porting

### Godot version

4.2

### System information

Windows 10.0.19045 - Vulkan (Forward+) - dedicated NVIDIA GeForce GTX 1060 (NVIDIA; 30.0.15.1403) - Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz (8 Threads)

### Issue description

When you use the `godot_console.exe` (the Windows wrapper executable) and open a program using Open External Program option in filesystem, closing the console will close the program. It does not happen with non-console executable.

### Steps to reproduce

1. Open godot console.exe
2. Open some file in External Program
3. Close the console
4. Godot closes
5. Program closes

### Minimal reproduction project

N/A
Repository: next.js
Issue: Use of a umd components library works with app router setup, but not page router setup
Labels: bug,SWC

### Link to the code that reproduces this issue

https://github.com/psylum/acl-poc-page

### To Reproduce

Specific commands related to package setup are included in the readme.

Perform a build or run the dev server.
```
$ npm run build
$ npm run dev
```

### Current vs. Expected behavior

Running a build fails, with the following output:
```
$ npm run build

> acl-poc-page@0.1.0 build
> next build

 ✓ Linting and checking validity of types    
   ▲ Next.js 14.0.3

 ✓ Creating an optimized production build    
 ✓ Compiled successfully
   Collecting page data  ../opt/acl-poc-page/node_modules/@astrouxds/react/dist/index.js:1
export * from "./components";
^^^^^^

SyntaxError: Unexpected token 'export'
    at internalCompileFunction (node:internal/vm:73:18)
    at wrapSafe (node:internal/modules/cjs/loader:1178:20)
    at Module._compile (node:internal/modules/cjs/loader:1220:27)
    at Module._extensions..js (node:internal/modules/cjs/loader:1310:10)
    at Module.load (node:internal/modules/cjs/loader:1119:32)
    at Module._load (node:internal/modules/cjs/loader:960:12)
    at Module.require (node:internal/modules/cjs/loader:1143:19)
    at mod.require (/opt/acl-poc-page/node_modules/next/dist/server/require-hook.js:64:28)
    at require (node:internal/modules/cjs/helpers:119:18)
    at 7922 (/opt/acl-poc-page/.next/server/pages/index.js:1:1326)

> Build error occurred
Error: Failed to collect page data for /
    at /opt/acl-poc-page/node_modules/next/dist/build/utils.js:1217:15
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
  type: 'Error'
}
   Collecting page data  .
```
Expected this to work, as it does using an app router setup (see https://github.com/psylum/acl-poc-app). I've variously tried using `transpilePackages`, and before attempting against latest, had webpack output an esm or cjs module, though umd would be preferable.

### 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 23.1.0: Mon Oct  9 21:27:27 PDT 2023; root:xnu-10002.41.9~6/RELEASE_X86_64
Binaries:
  Node: 18.18.2
  npm: 9.8.1
  Yarn: N/A
  pnpm: N/A
Relevant Packages:
  next: 14.0.3
  eslint-config-next: N/A
  react: 18.2.0
  react-dom: 18.2.0
  typescript: 5.3.2
Next.js Config:
  output: N/A
```


### Which area(s) are affected? (Select all that apply)

Not sure, SWC transpilation

### Additional context

This same behavior is seen in a pre-existing application using Next.js 13.2.3, i created these proof of concept apps using latest to reproduce the problem and verify it remained in the current release, so i could file this issue.
Repository: go
Issue: runtime: ~5% regression in ParallelizeUntil/pieces:1000,workers:10,chunkSize:1-8 sec/op at 450ecbe
Labels: Performance,NeedsInvestigation,compiler/runtime

From the performance dashboard, https://perf.golang.org/dashboard/?benchmark=regressions, I found a performance regression on a microbenchmark of contended channel operations (which involve a contended `runtime.mutex`), https://perf.golang.org/dashboard/?benchmark=ParallelizeUntil/pieces:1000,workers:10,chunkSize:1-8&unit=sec/op .

https://github.com/kubernetes/client-go/blob/v0.22.2/util/workqueue/parallelizer_test.go
https://github.com/kubernetes/client-go/blob/v0.22.2/util/workqueue/parallelizer.go

The benchmark runs on GOOS=linux, GOARCH=amd64 with GOMAXPROCS=8. It creates 10 workers which consume 1000 trivial work units from a shared channel. I've reproduced the regression on linux/amd64 and confirmed that it's introduced by https://go.dev/cl/544195 (and its predecessor, https://go.dev/cl/528657).

The magnitude of the regression is a ~5% slowdown on contended channel operations. On the hardware I used to test, they move from 174ns each for 10 workers on 8 threads (174µs for each `b.N` iteration, representing 1000 items) to 184ns.

CPU profiles show that extra 10ns goes to:
- `nanotime` (to mark the start and end of contended lock acquisitions, sampled at `gTrackingPeriod`)
- function call overhead
- the bookkeeping that's now part of all `runtime.unlock2` calls regardless of contention (to see if the M is storing contention info that needs to be moved to the `mprof` map)

Note that this code is active even with the default of `GODEBUG=profileruntimelocks=0`, because https://go.dev/cl/544195 reports the _magnitude_ of runtime-internal lock contention as part of the `/sync/mutex/wait/total:seconds` metric.

I've been able to reduce the overhead through sound changes (reducing the sample rate, structuring the function calls to convince the compiler to inline the fast paths into `runtime.lock2` and `runtime.unlock2`). I've been able to eliminate the overhead through an additional unsound change (to have `runtime.unlock2` only interact with the lock profile when it's waking another thread). That change isn't sound because promoting data into the `mprof` structure is only safe when we're unlocking the M's last lock (which might not be one for which another thread is waiting), but it's similar to the Go 1.23 plans that @prattmic and I discussed, wherein we'd capture the stack of the _unlocking_ thread and give it weight equivalent to how long it had delayed the other threads.

I'm not sure how much of a problem 10ns in this microbenchmark is in the big picture. But the above is what I learned when looking into it.

CC @prattmic @mknyszek 
CC @golang/runtime
Repository: vscode
Issue: Diff chunks not minimal if last line of added block equals last line of previous block, but differs by indentation
Labels: bug,diff-editor

<!-- ⚠️⚠️ Do Not Delete This! bug_report_template ⚠️⚠️ -->
<!-- Please read our Rules of Conduct: https://opensource.microsoft.com/codeofconduct/ -->
<!-- 🕮 Read our guide about submitting issues: https://github.com/microsoft/vscode/wiki/Submitting-Bugs-and-Suggestions -->
<!-- 🔎 Search existing issues to avoid creating duplicates. -->
<!-- 🧪 Test using the latest Insiders build to see if your issue has already been fixed: https://code.visualstudio.com/insiders/ -->
<!-- 💡 Instead of creating your report here, use 'Report Issue' from the 'Help' menu in VS Code to pre-fill useful information. -->
<!-- 🔧 Launch with `code --disable-extensions` to check. -->
Does this issue occur when all extensions are disabled?: Yes

<!-- 🪓 If you answered No above, use 'Help: Start Extension Bisect' from Command Palette to try to identify the cause. -->
<!-- 📣 Issues caused by an extension need to be reported directly to the extension publisher. The 'Help > Report Issue' dialog can assist with this. -->
- VS Code Version: 1.84.2
- OS Version: Windows 10 23H2

Steps to Reproduce:

[Playground](https://microsoft.github.io/monaco-editor/playground.html?source=v0.44.0#XQAAAAL1AgAAAAAAAABBqQkHQ5NjdMjwa-jY7SIQ9S7DNlzs5W-mwj0fe1ZCDRFc9ws9XQE0SJE1jc2VKxhaLFIw9vEWSxW3yscw2rGhjZmn-4FNw7EJFXfE5zHCAAPkGl4JHQWBB-9rQk5cWb5_-IQthYi5LCkIpStT1Cwli_WYwzdvtRT8dHAHP0tIUhOTizDTN-y4ZvehZNznUqDlHT3MsQxRiMSAFYwXZsVCxMVi0TYx22FRV5WBz6ghC9-pAxdCDml1tPLceiGcNWsR9FXz1OYAT7JXIpz0Bfk3q7bFV9yqXPnG9K3VnOhgOAA5UPup-jJNQQM3GSbbdcIs-Q3-j5KMzyYTWNc9lo0pqHBs1N3WGu3G-M9YKbSpwHrFvLcJP2ssv37NA810bohIJOZv0Jez_I0eTMJeZvpbOVDOqxO53QzPeB-E89mBZuScSZYvQ4Qas2hldn5wn_JRq71fP83GHY83qZrqZ6A3hulR__BgPvo)

From left to right, I have added `import A` and `if Z: return`. I did not change `if X: if Y: return`, but that return is shown as part of the diff.

![image](https://github.com/microsoft/vscode/assets/12128514/dfe7f3ab-1cbd-46a0-a52c-e70fcfa2098e)

The diff should show `import A` and `if Z: return` as added blocks, and nothing else.
Repository: pytorch
Issue: Unsupported: call_method UserDefinedObjectVariable(_profiler_enabled) __call__ [] {}
Labels: triaged,module: graph breaks

user source that triggered, should be easy to repro:
```
    if torch.autograd._profiler_enabled():
```