sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: next.js
Issue: Using ky with edge functions works on prod but fails on local Next.js dev server
Labels: bug,Runtime

### Verify canary release

- [X] I verified that the issue exists in the latest Next.js canary release

### Provide environment information

    Operating System:
      Platform: darwin
      Arch: x64
      Version: Darwin Kernel Version 21.6.0: Mon Aug 22 20:17:10 PDT 2022; root:xnu-8020.140.49~2/RELEASE_X86_64
    Binaries:
      Node: 16.18.0
      npm: 8.19.2
      Yarn: 1.22.19
      pnpm: 7.13.5
    Relevant packages:
      next: 12.3.2-canary.29
      eslint-config-next: 12.3.1
      react: 18.2.0
      react-dom: 18.2.0

### What browser are you using? (if relevant)

106.0.5249.119

### How are you deploying your application? (if relevant)

next dev

### Describe the Bug

[ky](https://github.com/sindresorhus/ky) is a small wrapper around `fetch`. The following edge function works fine in production: https://next-edge-test-yl6y.vercel.app/api/ky, but it produces an error when run locally with `next dev`:

```ts
import { NextRequest, NextResponse } from 'next/server'
import ky from 'ky'

export default async function handler(req: NextRequest) {
  const data = await ky
    .post('https://httpbin.org/post', {
      json: { test: true }
    })
    .json()
  console.log(data)

  return NextResponse.json(data)
}

export const config = {
  runtime: 'experimental-edge'
}
```
([source](https://github.com/transitive-bullshit/next-edge-test/blob/main/pages/api/ky.ts))

Visiting this edge function locally results in the error "TypeError: Request with GET/HEAD method cannot have body.":

<img width="982" alt="Screen Shot 2022-10-18 at 1 43 09 PM" src="https://user-images.githubusercontent.com/552829/196506186-addc72ee-1392-45b8-b630-c791bf0ff55f.png">

### Expected Behavior

Visiting this edge function locally should work as it does in production, producing a valid JSON output: https://next-edge-test-yl6y.vercel.app/api/ky

This is presumably due to some inconsistency with how Next.js is polyfilling `fetch` or one of it's related globals. Is Next.js properly polyfilling all of the related globals as `ky-universal` does here? https://github.com/sindresorhus/ky-universal/blob/main/index.js

### Link to reproduction

https://github.com/transitive-bullshit/next-edge-test

### To Reproduce

1. Clone https://github.com/transitive-bullshit/next-edge-test/blob/main/pages/api/ky.ts
2. yarn install (or whatever package manager)
3. yarn dev
4. Visit `http://localhost:3000/api/ky`
Repository: flutter
Issue: Talkback doesn't always see platform view contents in Hybrid Composition mode
Labels: platform-android,engine,a: accessibility,a: platform-views,P3,platform-views: hc,team-android,triaged-android

During investigation of https://github.com/flutter/flutter/issues/101887 I'm seeing that platform view accessibility seems to be broken in at least some cases in Hybrid Composition.

Example steps to reproduce:
- Run the example app from `webview_flutter`, making sure it's in HC mode (currently that's true by default because of the transparent background.)
- Run on Android with Talkback enabled, and try to get to the web view contents.

What I'm seeing is that the webview is completely invisible to Talkback (not only tapping, but if I enable the "dump node tree" option in Talkback developer settings, the resulting tree doesn't list the webview). It appears that this is due to the overlay view that displays the widgets that are over the platform view in the Flutter widget tree (in this case the favorites button); if I run with a local engine modified to not add the overlay view to the Flutter view, it's in the a11y node tree and can be inspected by tapping as expected (although of course other things are broken). It may be that this only happens if there are actually overlays, but I haven't investigated that yet.

The same test works fine in TLHC mode, which is not surprising since we don't use an overlay view for TLHC.

I'm not familiar enough with the internals of Android's a11y system to know why this happens; naively I would expect fully transparent view overlays to mask a11y elements that are underneath them. If possible, we need to find a way to have only the opaque parts of the overlay be treated by the a11y system as hiding what is underneath them. (/cc @chunhtai @bparrishMines )
Repository: flutter
Issue: [flutter_tools] tool should stop using deprecated `dart2js` snapshot
Labels: tool,P2,team-tool,triaged-tool

If there is a web compilation error, users will see a deprecation error from having used dart2js rather than the replacement dart compile js. Even though this should not cause compilation to fail, it will confuse users, and we should migrate.

For example:

```
jimgraham-macbookpro2% flutter run --profile -d chrome --web-renderer=canvaskit
Launching lib/main.dart on Chrome in profile mode...
Target dart2js failed: Exception: Warning: The 'dart2js' entrypoint script is deprecated, please use 'dart compile js'
instead.
../../flutter/packages/flutter/lib/src/widgets/image_filter.dart:5:8:
Error: Not found: 'dart:ffi'
import 'dart:ffi';
       ^
Error: Compilation failed.


#0      Dart2JSTarget.build (package:flutter_tools/src/build_system/targets/web.dart:216:7)
<asynchronous suspension>
#1      _BuildInstance._invokeInternal (package:flutter_tools/src/build_system/build_system.dart:847:9)
<asynchronous suspension>
#2      Future.wait.<anonymous closure> (dart:async/future.dart:522:21)
<asynchronous suspension>
#3      _BuildInstance.invokeTarget (package:flutter_tools/src/build_system/build_system.dart:785:32)
<asynchronous suspension>
#4      Future.wait.<anonymous closure> (dart:async/future.dart:522:21)
<asynchronous suspension>
#5      _BuildInstance.invokeTarget (package:flutter_tools/src/build_system/build_system.dart:785:32)
<asynchronous suspension>
#6      FlutterBuildSystem.build (package:flutter_tools/src/build_system/build_system.dart:614:16)
<asynchronous suspension>
#7      buildWeb (package:flutter_tools/src/web/compile.dart:48:32)
<asynchronous suspension>
#8      ResidentWebRunner.run.<anonymous closure> (package:flutter_tools/src/isolated/resident_web_runner.dart:293:11)
<asynchronous suspension>
#9      asyncGuard.<anonymous closure> (package:flutter_tools/src/base/async_guard.dart:111:24)
<asynchronous suspension>

Compiling lib/main.dart for the Web...                              4.2s
Exception: Failed to compile application for the Web.
```
Repository: flutter
Issue: [flutter_tools] RPCError: lookupResolvedPackageUris: (-32603)
Labels: tool,platform-web,P2,team-web,triaged-web

on `beta/3.4.0-34.1.pre`
with command `flutter debug_adapter`

```
RPCError: lookupResolvedPackageUris: (-32603)
lookupResolvedPackageUris: [Sentinel kind: Collected, valueAsString: Unrecognized isolateId: 2157] from lookupResolvedPackageUris()
#0      ChromeProxyService._throwSentinel (package:dwds/src/services/chrome_proxy_service.dart:1104:5)
#1      ChromeProxyService._checkIsolate (package:dwds/src/services/chrome_proxy_service.dart:1096:7)
#2      ChromeProxyService.lookupResolvedPackageUris (package:dwds/src/services/chrome_proxy_service.dart:686:5)<asynchronous suspension>
#3      StackZoneSpecification._registerUnaryCallback.<anonymous closure> (package:stack_trace/src/stack_zone_specification.dart:125:47)<asynchronous suspension>

at new _OutstandingRequest(vm_service.dart:1746)
at VmService._call(vm_service.dart:2262)
at VmService.lookupResolvedPackageUris(vm_service.dart:2095)
at IsolateManager._lookupResolvedPackageUris(isolate_manager.dart:550)
at ThreadInfo.resolveUrisToPathsBatch(isolate_manager.dart:910)
at ThreadInfo.resolveUrisToPackageLibPathsBatch(isolate_manager.dart:877)
at IsolateManager._sendLibraryDebuggables(isolate_manager.dart:720)
at <asynchronous gap>(async)
at Future.wait.<anonymous closure>(future.dart:522)
at <asynchronous gap>(async)
at IsolateManager._configureIsolate(isolate_manager.dart:361)
at <asynchronous gap>(async)
at IsolateManager.registerIsolate(isolate_manager.dart:215)
at <asynchronous gap>(async)
at IsolateManager.handleEvent(isolate_manager.dart:163)
at <asynchronous gap>(async)
at DartDebugAdapter.handleIsolateEvent(dart.dart:1859)
at <asynchronous gap>(async)
at DartDebugAdapter._withErrorHandling(dart.dart:2100)
at <asynchronous gap>(async)
```
Repository: pytorch
Issue: nvprims.div doesn't work with FakeTensor cpu scalars
Labels: triaged,module: nvfuser,module: fakeTensor

### 🐛 Describe the bug


```py
import torch
from torch.fx.experimental.proxy_tensor import make_fx
from torch._subclasses.fake_tensor import FakeTensor

meta_scalar = torch.zeros((), device="meta")
meta_tensor = torch.zeros((3, 3), device="meta")

with torch._subclasses.fake_tensor.FakeTensorMode() as mode:
    fake_cpu_scalar = FakeTensor(mode, meta_scalar, torch.device("cpu"))
    fake_cuda_tensor = FakeTensor(mode, meta_tensor, torch.device("cuda"))

gm = make_fx(lambda a, b: torch.ops.nvprims.div(a, b))(fake_cuda_tensor, fake_cpu_scalar)
```
```py
File ~/dev/pytorch/master/torch/_prims_common/__init__.py:612, in check_same_shape(allow_cpu_scalar_tensors, *args)
    608     if not is_same_shape(shape, arg.shape):
    609         msg = "Shape {0} is not the expected shape {1}!".format(
    610             arg.shape, shape
    611         )
--> 612         raise RuntimeError(msg)
    613 else:
    614     msg = (
    615         "Unexpected type when checking for same shape, " + str(type(arg)) + "!"
    616     )

RuntimeError: Shape torch.Size([]) is not the expected shape torch.Size([3, 3])!
```
It works fine with `torch.ops.prims.div`.

### Versions

Latest master.

cc @kevinstephano @jjsjann123
Repository: godot
Issue: Opening project in editor and pressing Play before fully loaded, causes onready variables to crash
Labels: bug,topic:editor,needs testing,crash

### Godot version

v3.5.1.stable.official [6fed1ffa3]

### System information

Windows 7 + Void Linux

### Issue description

When I open SM63 Redux in Godot 3.5.1's editor, then (before the editor finishes loading) I press F5 to play the project, the project prints errors in the output pane (see below) and crashes to a debugger break once you select "Story Mode".

```
 res://classes/solid/log/log_fall.gd:10 - Parse Error: The identifier "RideArea" isn't a valid type (not a script or class), or couldn't be found on base "self".
 res://classes/player/player.gd:86 - Parse Error: The identifier "BaseModifier" isn't declared in the current scope.
```

The code at the site of each crash:

https://github.com/GTcreyon/SM63Redux/blob/1993b3fd6bff0be2900651db195a127cdf77a6d4/classes/solid/log/log_fall.gd#L10

https://github.com/GTcreyon/SM63Redux/blob/1993b3fd6bff0be2900651db195a127cdf77a6d4/classes/player/player.gd#L86

Both are type hints on `onready` variables, with types corresponding to `class_name` types defined by this project (https://github.com/GTcreyon/SM63Redux/blob/1993b3fd6bff0be2900651db195a127cdf77a6d4/classes/ride_area.gd and https://github.com/GTcreyon/SM63Redux/blob/1993b3fd6bff0be2900651db195a127cdf77a6d4/classes/base_modifier.gd). I don't know the exact conditions causing this bug, or the cause, and can't make a minimal project since I didn't write this code and don't understand it or Godot, but it looks like Godot is failing to lookup the type names specified in the *type hints* (not even executable code).

Additionally after you press F5 too early, the first time you click from the game into the Godot editor, you get a godot-rust panic in the output, with output "`pipescript::PipeScript` has already been registered as `PipeScript`" and full stack trace in the terminal. (See https://github.com/godot-rust/godot-rust/issues/959#issuecomment-1282944300 for details.) I suspect Godot is running the godot-rust init callback twice without unregistering in between, but IDK if this is the same or a different bug. These two bugs might be related, since both are related to registering types in the global namespace if you start the project before Godot's editor finishes loading.

### Steps to reproduce

- Clone https://github.com/GTcreyon/SM63Redux.
- Open Godot, add the folder into the project list, then double-click the project item.
- While the editor is still loading and showing a black screen, press F5 to play the project.

### Minimal reproduction project

_No response_
Repository: rust
Issue: tuple struct expressions with non-visible (private) fields should bias towards suggesting methods
Labels: A-diagnostics,T-compiler

Given the following code ([play](https://play.rust-lang.org/?version=nightly&mode=debug&edition=2021&gist=bda7f897fd748b52731a1f3dd0e61d2e)): 

```rust
fn main() {
    let f = std::fs::File::open("/proc/meminfo").unwrap();
    let b = std::io::BufReader(f);
    for line in b.lines() { dbg!(line); }
}
```

The current output is:

```
error[[E0423]](https://doc.rust-lang.org/nightly/error-index.html#E0423): expected function, tuple struct or tuple variant, found struct `std::io::BufReader`
 --> src/main.rs:3:13
  |
3 |     let b = std::io::BufReader(f);
  |             ^^^^^^^^^^^^^^^^^^^^^ help: use struct literal syntax instead: `std::io::BufReader { inner: val, buf: val }`
```

Ideally the output should look like:

```
3 |     let b = std::io::BufReader(f);
  |             ^^^^^^^^^^^^^^^^^^^^^ help: use constructor method instead: `std::io::BufReader::new(f)`
```

----

In other words: If a type from an external crate has non-public fields, we should not be suggesting the user attempt to use them for constructing an instance of the type. *Especially* in the case of tuple struct expressions, which can be a sign of an omitted constructor method name. (I'm thinking specifically of people who are coming from Java, and thus may be used to writing something like `new BufReader(f)` where we would write `BufReader::new(f)`.)

A simple heuristic here could be to look for methods on the type that 1. do not take `self` parameter, and 2. (optional) have a matching number of arguments

----

This issue is similar to #66067 and #52144, except worse, because (if I understand them correctly) those two are both talking about improving the UX for incorrect tuple struct expressions that at least are also referring to tuple struct definitions.

In the scenario described here, we have a *record struct* definition being used as a tuple struct, which, in the presence of private fields, we should interpret as a strong hint that someone probably meant to use a method.
Repository: vscode
Issue: [css] Custom aliases in CSS file resolution
Labels: feature-request,css-less-scss

Please read from ``tsconfig``/``jsconfig`` to resolve SCSS modules. My suggestion to make this reliable is to simply only allow the import aliases to work inside of an aliased directory, and in every subfolder starting from the ``tsconfig``/``jsconfig`` as the root, so that we can theoretically open huge projects with weird build settings and have a sane default for it. The ``tsconfig``/``jsconfig`` essentially define majority of these weird quirks such as these path aliases for the entire IDE, and we should just stick to allowing this to continue even if it "makes no sense" to read from these files for what is "just SCSS".

If this won't be supported, we could at least make it possible to define these aliases in the .vscode settings.json and then use those paths across the IDE as the standard. No matter what though, we need these path aliases as for large projects not being able to jump to the definition of an imported module is very annoying.
Repository: flutter
Issue: Highlight Repaints is not available in CLI menu
Labels: c: new feature,tool,P3,team-tool,triaged-tool

<img width="1021" alt="Screen Shot 2022-10-18 at 5 23 33 PM" src="https://user-images.githubusercontent.com/666539/196547697-24039732-bde5-435b-928f-4975d9194afa.png">

<img width="832" alt="Screen Shot 2022-10-18 at 5 24 04 PM" src="https://user-images.githubusercontent.com/666539/196547709-a99eb754-7c76-4749-9582-e50974297608.png">

`Highlight Repaints` appears to only be available through DevTools and integrations with IDEs. It is not available through the CLI tools.
Repository: go
Issue: cmd/go: confusing error message when flags come before package paths
Labels: Unfortunate,NeedsInvestigation,GoCommand

```txtar
-- go.mod --
module m

go 1.19
-- x/t_test.go --
package x

// some test code that has a -foo flag
```

(Warning: hand-written, untested txtar.)

```
$ go test ./x -foo
<OK>
$ go test -foo ./x
no Go files in /current/pwd
```

This is a confusing error message. I think(?) the Go tool has interpreted `-foo` as a package path, but the error message doesn't reflect that. It's true that there are no Go files in the root, but that's not the problem.

Maybe the Go command could make these two equivalent. But even if it can't, a more useful error message would be welcome.
Repository: stable-diffusion-webui
Issue: Convert multi-parens emphesis to new format in PNG & TXT generation parameters
Labels: enhancement

**Is your feature request related to a problem? Please describe.**
Prompt sharing of already existing images is done most easily by copy-pasting the generation parameters from the PNG Info tab or the text files next to the image. Since there already is a more versatile alternate pattern for emphasis than multi parenthesis, the following could promote adaption. In addition, the old syntax has an unfortunate association with hate speech for a certain special case (see additional context below)

**Describe the solution you'd like**
Automatically convert multi parens / brackets emphasis to the new format when the generation parameters are saved "as chunks to png files" or directly to "text file next to image" (as specified in settings tab).
* `(word) & [word]` → stays as is
* `((word)) & [[word]]` → will be saved as `(word:1.21) & (word:0.81)`
* `(((word))) & [[[word]]]` → `(word:1.33) & (word:0.73)` rounded to two digits

**Describe alternatives you've considered**
The following, while more consistent and precise, introduce visual noise and hamper readability
* `(word)` → ~(word:1)~ /edit `(word:1.1)`
* `(((word)))` → `(word:1.331)`

**Pitfalls**
This may be less trivial to implement for cases like
`prompt with an ((important section that has a ((really important part))))`

**Additional context**
A [Reddit thread](https://www.reddit.com/r/sdforall/comments/y6a3e9/warning_reddit_permanently_banned_a_user_for/) suggests that the use of triple parenthesis emphasis in a posted prompt may have triggered the anti-hate filters and led to the ban of a user. [Triple parenthesis](https://en.wikipedia.org/wiki/Triple_parentheses) seems to be an antisemitic symbol on social media.
Repository: material-ui
Issue: [TextField] TS error when TextField select multiple onChange signature uses 2 arguments
Labels: bug 🐛,component: text field,typescript

### Duplicates

- [X] I have searched the existing issues

### Latest version

- [X] I have tested the latest version

### Steps to reproduce 🕹

Steps:

1. Create `TextField` with `select` prop and `SelectProps[mulitple]`
2. Pass a function with two arguments as you would when using `Select` with `multiple`

### Current behavior 😯

TS will throw error
```
Type '(e: any, child: any) => void' is not assignable to type 'ChangeEventHandler<HTMLInputElement | HTMLTextAreaElement>'.
```

### Expected behavior 🤔

When using multiple select, the second argument is the clicked option. Putting the @ts-ignore on the error and console logging the second argument will show the object, as you would on the `Select` component.

### Context 🔦

_No response_

### Your environment 🌎

<details>
  <summary><code>npx @mui/envinfo</code></summary>

```
  System:
    OS: Windows 10 10.0.19042
    CPU: (16) x64 AMD Ryzen 7 2700X Eight-Core Processor
    Memory: 11.70 GB / 31.93 GB
  Binaries:
    Node: 16.15.0 - C:\Program Files\nodejs\node.EXE
    Yarn: 1.22.10 - ~\AppData\Roaming\npm\yarn.CMD
    npm: 8.5.5 - C:\Program Files\nodejs\npm.CMD
    Watchman: 20210102.202219.0 - C:\Users\roger\watchman\bin\watchman.EXE
  Utilities:
    Git: 2.30.0.
  IDEs:
    Android Studio: AI-212.5712.43.2112.8815526
    VSCode: 1.71.2 - C:\Users\roger\AppData\Local\Programs\Microsoft VS Code\bin\code.CMD
    Visual Studio: 15.9.28307.1401 (Visual Studio Community 2017)
  Languages:
    Bash: 5.0.17 - C:\Windows\system32\bash.EXE
    Java: 17.0.1
    Python: 2.7.18
  Databases:
    PostgreSQL: 10.15 - C:\Program Files\PostgreSQL\10\bin\postgres.EXE
    SQLite: 3.32.2 - C:\platform-tools\sqlite3.EXE
  Browsers:
    Edge: Spartan (44.19041.1266.0), Chromium (106.0.1370.47)
    Internet Explorer: 11.0.19041.1202
```
</details>
Repository: vscode
Issue: Allow notebook renderers to access additional output mimes
Labels: feature-request,api-proposal,notebook-api

For https://github.com/microsoft/vscode-jupyter/issues/8635

This tracks allowing a notebook renderer to see all mime typed data associated with the currently rendered item

A custom renderer can use this data to fallback to render a different mime (this is what is needed for  https://github.com/microsoft/vscode-jupyter/issues/8635)
Repository: godot
Issue: [TRACKER] Render reorganisation
Labels: topic:rendering,tracker

Will be working on detailing this properly in the next few hours but after our rendering meeting we've decided to create a tracker for all the work done around the reorg and to list things still left to do.

**This tracker only tracks issues in the `master` branch**, not `3.x`.

```[tasklist]
### Bugs
- [x] https://github.com/godotengine/godot/pull/65068
- [ ] https://github.com/godotengine/godot/issues/66857
```

```[tasklist]
### Enhancements
- [x] https://github.com/godotengine/godot/pull/59062
- [x] https://github.com/godotengine/godot/pull/59347
- [x] https://github.com/godotengine/godot/pull/59385
- [x] https://github.com/godotengine/godot/pull/59807
- [x] https://github.com/godotengine/godot/pull/59984
- [x] https://github.com/godotengine/godot/pull/60547
- [x] https://github.com/godotengine/godot/pull/60617
- [x] https://github.com/godotengine/godot/pull/61221
- [x] https://github.com/godotengine/godot/pull/62344
- [x] https://github.com/godotengine/godot/pull/62478
- [x] https://github.com/godotengine/godot/pull/63273
- [x] https://github.com/godotengine/godot/pull/63345
- [x] https://github.com/godotengine/godot/pull/63527
- [x] https://github.com/godotengine/godot/pull/63901
- [x] https://github.com/godotengine/godot/pull/65469
- [x] https://github.com/godotengine/godot/pull/65822
- [x] https://github.com/godotengine/godot/pull/70253
- [x] https://github.com/godotengine/godot/issues/64478
- [ ] https://github.com/godotengine/godot/issues/67602
- [ ] https://github.com/godotengine/godot/issues/67603
- [ ] https://github.com/godotengine/godot/issues/67604
- [ ] Final cleanup/round-off of render_scene_render around entry points and storage of settings
```

```[tasklist]
### Proposals
- [ ] https://github.com/godotengine/godot-proposals/issues/5616
```