sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: flutter
Issue: Unnecessary Chrome error on a Windows machine with Chromium Edge
Labels: tool,platform-windows,t: flutter doctor,a: quality,platform-web,P2,team-web,triaged-web

## Steps to Reproduce
On a Windows 10/11 machine with Chromium Edge, we have everything we need to build and run Flutter apps on the web. Yet `flutter doctor` reports an error if Google Chrome is not installed, as shown in the log below.

While we would naturally _encourage_ all developers to install Chrome, we should detect the presence of Chromium Edge and use it without further configuration. Notice that the Edge browser itself is successfully detected (see "Connected device" section). 

## Logs

<details>
<summary>Logs</summary>

```
[C:\src] flutter doctor -v
[✓] Flutter (Channel master, 2.6.0-6.0.pre.147, on Microsoft Windows [Version 10.0.22000.194], locale en-US)
    • Flutter version 2.6.0-6.0.pre.147 at c:\src\flutter
    • Upstream repository git@github.com:flutter/flutter.git
    • Framework revision 83dfb2237a (2 days ago), 2021-09-17 23:48:04 -0400
    • Engine revision 31792e0340
    • Dart version 2.15.0 (build 2.15.0-120.0.dev)

[✗] Chrome - develop for the web (Cannot find Chrome executable at .\Google\Chrome\Application\chrome.exe)
    ! Cannot find Chrome. Try setting CHROME_EXECUTABLE to a Chrome executable.

[✓] Visual Studio - develop for Windows (Visual Studio Professional 2022 17.0.0 Preview 4.0)
    • Visual Studio at C:\Program Files\Microsoft Visual Studio\2022\Preview
    • Visual Studio Professional 2022 version 17.0.31710.8
    • The current Visual Studio installation is a pre-release version. It may not be supported by Flutter yet.
    • Windows 10 SDK version 10.0.20348.0

[✓] VS Code (version 1.60.1)
    • VS Code at C:\Users\Tim Sneath\AppData\Local\Programs\Microsoft VS Code
    • Flutter extension version 3.26.0

[✓] Connected device (2 available)
    • Windows (desktop) • windows • windows-x64    • Microsoft Windows [Version 10.0.22000.194]
    • Edge (web)        • edge    • web-javascript • Microsoft Edge 90.0.818.66

! Doctor found issues in 1 category.
```

</details>
Repository: PowerToys
Issue: [PT run] Initial selection is not consistent and sometimes even incorrect
Labels: Issue-Bug,Product-PowerToys Run,Needs-Team-Response

### Microsoft PowerToys version

0.45.0

### Running as admin

- [X] Yes

### Area(s) with issue?

PowerToys Run

### Steps to reproduce

# Inconsistent selection highlighting

I have no 1:1 reproduction steps as this behavior is most probably highly dependant on the indexed files & search history but I can explain what happens:

When typing something, most of the time the first entry in the result list is highlighted so that I know at one glance that this will be executed when pressing enter without moving the selection at all. However, sometimes nothing is selected:

https://user-images.githubusercontent.com/30658772/133963383-e5a3e183-4d5f-49c3-bc5f-c484bde6f236.mp4

As you can see in this video:
* ✅ When searching for `fire`, the first entry is selected.
* ❌ When searching for `finan`, the first entry is not selected as expected.
  However, when pressing enter in this state, the first entry is still executed.

# Incorrect selection highlighting

Sometimes it even happens, that the wrong entry is selected:

https://user-images.githubusercontent.com/30658772/133963867-6998278a-16f0-4169-8233-890e6181d366.mp4

Here, I only typed `fin` and did **not** move the selection, however, it is still the second entry which is highlighted. What is even more confusing then: When I press enter in the shown state, the first entry `FinanceControl` gets executed, not the highlighted one 🤷‍♂️

### ✔️ Expected Behavior

* Always highlight the first entry after typing
* Always execute the item which is highlighted when pressing `enter`

### ❌ Actual Behavior

* Sometimes no entry is highlighted at all
* Sometimes incorrect entry is highlighted

### Other Software

_No response_
Repository: go
Issue: x/tools/go/packages: Config.Env doesn't support -modfile
Labels: NeedsInvestigation,Tools

```
% go version
go version go1.17 darwin/amd64
% cat main.go go.mod
package main

import (
	"log"
	"os"

	"golang.org/x/tools/go/packages"
)

func main() {
	_, err := packages.Load(&packages.Config{
		Mode: packages.NeedName | packages.NeedFiles | packages.NeedImports | packages.NeedDeps,
		Env:  os.Environ(),
	}, ".")
	if err != nil {
		log.Fatal(err)
	}
}
module example.com

go 1.17

require golang.org/x/tools v0.1.6

require (
	golang.org/x/mod v0.4.2 // indirect
	golang.org/x/sys v0.0.0-20210809222454-d867a43fc93e // indirect
	golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 // indirect
)
% go run .
% GOFLAGS=-modfile=go.mod go run .
2021/09/20 08:48:46 err: exit status 1: stderr: build flag -modfile only valid when using modules
exit status 1
```

I'd like to support GOFLAGS=-modfile=... from tools that use packages.Load, but perhaps more concerning is that the error message indicates some go tool commands are run in non-module mode.
Repository: TypeScript
Issue: Single underscore not detected as unused in import statement
Labels: Suggestion,Awaiting More Feedback

# Bug Report

### 🔎 Search Terms

unused underscore

### 🕗 Version & Regression Information

- This is the behavior in every version I tried.

### ⏯ Playground Link

https://www.typescriptlang.org/play?noUnusedParameters=true#code/FASwtgDg9gTgLgAgPoIGYymBAiArgOwBMBTGAZwGNZjsBuUSWRAEjQy2wCsBHXUgTzrAgA

### 💻 Code

```ts
import _ from "underscore";
import $ from "jquery";
```

### 🙁 Actual behavior

The JQuery import is marked as unused, but the Underscore import is not.

### 🙂 Expected behavior

A single `_` is not treated as an identifier with leading "unused marker", but as regular identifier.
Repository: create-react-app
Issue: typescript template not installing webpack
Labels: stale,needs triage

If you have a general question about Create React App or about building an app with Create React App we encourage you to post in GitHub Discussions instead of this issue tracker. The maintainers and other community members can provide help and answer your questions there: https://github.com/facebook/create-react-app/discussions

If you're looking for general information on using React, the React docs have a list of resources: https://reactjs.org/community/support.html

If you've discovered a bug or would like to propose a change please use one of the other issue templates.

Thanks!
Repository: godot
Issue: [3.x] Multiple shortcuts being triggered at once / shortcuts not triggering correctly / shortcuts not respecting the "context" in which they were executed
Labels: bug,topic:editor,confirmed,tracker,topic:input

### Godot version

3.x

### System information

All Platforms

### Issue description

In 3.x editor shortcuts can have unexpected behavior, as described in the title. This is commonly reported so this is a central issue to direct all discussion if required.

This was fixed in 4.0 by #42109

```[tasklist]
### Related
- [ ] #51948
- [ ] #50271
- [ ] #47873
- [ ] #36205
- [ ] #38922
- [ ] #37807
- [ ] #37054
- [ ] #17591
- [ ] #35834
- [ ] #31779
- [ ] #46678
- [ ] #57377
- [ ] #45621
- [ ] #58076
- [ ] #63828
- [ ] #63831
```

### Steps to reproduce

Various

### Minimal reproduction project

_No response_
Repository: opencv
Issue: Bug in UIImageToMat when dealing with PNG files
Labels: platform: ios/osx,category: swift/objc bindings

##### System information (version)
- OpenCV => 4.5.2
- Operating System / Platform => iOS 11.5.2
- Compiler => XCode

##### Detailed description

I have a png file with alpha channel, and I am using UIImageToMat with alphaExist = true for converting this image from UIImage* type to cv::Mat type, however the UIImageToMat does not create the same image. See the original image and the same image after it is passed to MatToUIImage. They are supposed to be exactly the same but they are different as you can see. Is this a bug? and how I can make a code change to make these two images the same?

##### Steps to reproduce

1) Read the image "L4_Original.png" by the following code:
my_uiimage = UIImage(named: "L4_Original") 

2) Then convert the image from UIImage* type to cv::Mat type
UIImageToMat(uiimage_ol4, editor.g_img_overlay4_orig, true);

3) Finally save the resulting image and name it as L4_reconstruct.png
imwrite("L4_reconstruct.png", editor.g_img_overlay4_orig);

4) As shown in the attachment. L4.png and L4_reconstruct.png are not the same. Is there an issue and whether it can be fixed?

![L4_Original](https://user-images.githubusercontent.com/49408687/133971448-97ee4765-0c30-47e7-9184-8305f71d74ee.png)
![L4_reconstruct](https://user-images.githubusercontent.com/49408687/133971451-4afed91e-4dbc-4eb3-b1a7-282d309019c5.png)
Repository: create-react-app
Issue: err npx create-react-app my-app 
Labels: stale

Program 'npx.cmd' failed to run: Access is deniedAt line:1 char:1
+ npx create-react-app my-app
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~.
At line:1 char:1
+ npx create-react-app my-app
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ResourceUnavailable: (:) [], ApplicationFailedException
    + FullyQualifiedErrorId : NativeCommandFailed
Repository: PowerToys
Issue: [PowerToys Run] Shell execution of batch files with args fails
Labels: Issue-Bug,Product-PowerToys Run,Priority-2,Run-Plugin

### Microsoft PowerToys version

0.45.0

### Running as admin

- [X] Yes

### Area(s) with issue?

PowerToys Run

### Steps to reproduce

Execute a batch file from PowerToys Run when the execution command:
- Includes arguments
- Does not include the .bat extension

For example: `> MyScript foo`

### ✔️ Expected Behavior

When entered into Windows Run, the batch file executes normally (and the arguments are passed as expected), regardless of whether the extension is included or not.

### ❌ Actual Behavior

The script fails to run at all:
![image](https://user-images.githubusercontent.com/91045489/133971808-dac5ff4e-aa33-48b4-a5da-3897df7262d1.png)

It works as expected if the command includes the extension or does not include any arguments.

### Other Software

It fails with any batch file, but I was testing using a simple shortcut script that runs `sync -r -e %~1`, flushing and ejecting the specified drive.

I was attempting to execute it using the command `> eject d` in PowerToys Run, with `>` as the direct activation command for the Shell plugin.
Repository: storybook
Issue: Angular regression `Error trying to diff '[...]' Only arrays and iterables are allowed` when using array properties
Labels: bug,angular,block: argstable

**Describe the bug**
Somewhere after `6.4.0-alpha.33` my stories which have an array property with a initial value started to break.

```
@Component({
  selector: 'app-toolbar',
  template: `<div
      class="texteditor-toolbar"
      role="toolbar"
      aria-orientation="horizontal"
    >
      <ng-container *ngFor="let tool of toolbar; let i = index">
        <button
          class="texteditor-toolbar-action"
          [title]="tool.title"
          tabindex="-1"
        >
          {{ tool.icon }}
        </button>
      </ng-container>
    </div>`,
})
export default class ToolbarComponent {
  public toolbar: ToolConfig[] = [
    {
      action: 'heading',
      options: { level: 1 },
      icon: 'heading1',
      title: 'Heading 1',
    },
    {
      action: 'heading',
      options: { level: 2 },
      icon: 'heading2',
      title: 'Heading 2',
    },
  ];
}
```

This code results in the following error in the console:

```
Error trying to diff '[
    {
      action: 'heading',
      options: { level: 1 },
      icon: 'heading1',
      title: 'Heading 1',
    },
    {
      action: 'heading',
      options: { level: 2 },
      icon: 'heading2',
      title: 'Heading 2',
    },
  ]'. Only arrays and iterables are allowed
```

This appears to happen because storybook tries to set the value of the array it extracted from compodoc as a string. When  I add `/** @ignore */` to this property it doesn't happen anymore, because the property is excluded from the documentation. But this isn't really desirable.

**To Reproduce**
https://github.com/stefan-schweiger/sb-angular-iterator-bug

**System**
```
System:
  OS: Windows 10 10.0.19043
  CPU: (12) x64 Intel(R) Core(TM) i7-10850H CPU @ 2.70GHz
Binaries:
  Node: 14.17.6 - C:\Program Files\nodejs\node.EXE       
  Yarn: 1.22.10 - ~\AppData\Roaming\npm\yarn.CMD
  npm: 6.14.15 - C:\Program Files\nodejs\npm.CMD
Browsers:
  Edge: Spartan (44.19041.1023.0), Chromium (93.0.961.52)
npmPackages:
  @storybook/addon-actions: ^6.4.0-alpha.39 => 6.4.0-alpha.39
  @storybook/addon-essentials: ^6.4.0-alpha.39 => 6.4.0-alpha.39
  @storybook/addon-links: ^6.4.0-alpha.39 => 6.4.0-alpha.39
  @storybook/angular: ^6.4.0-alpha.39 => 6.4.0-alpha.39
  @storybook/builder-webpack5: ^6.4.0-alpha.39 => 6.4.0-alpha.39
  @storybook/manager-webpack5: ^6.4.0-alpha.39 => 6.4.0-alpha.39
```
Repository: flutter
Issue: [Image_picker]: Image gallery opens twice if we choose select photos permission.
Labels: c: regression,platform-ios,customer: crowd,p: image_picker,package,has reproducible steps,P2,found in release: 3.10,found in release: 3.11,team-ios,triaged-ios

Hi. Issue https://github.com/flutter/flutter/issues/78108 still present in Image Picker

**Flutter version:** 2.5.1
**image_picker version:** 0.8.4+2
**IOS version:** 14.7.1
Repository: flutter
Issue: Use null aware operators on _ButtonStyleState
Labels: framework,f: material design,a: null-safety,team-design,triaged-design

I was extending `ButtonStyleButton` to make my own custom vertical script buttons. After updating to Flutter 2.5, I'm getting an internal crash button `_ButtonStyleState` when it is trying to resolve the constraints ([here](https://github.com/flutter/flutter/blob/02b46b0d775166463416b85c80ad5c428ad8be6f/packages/flutter/lib/src/material/button_style_button.dart#L260)). The crash is caused by using the null assertion operator on a null value. Maybe this is never null for the standard Flutter buttons, but since `ButtonStyleButton` is public, I recommend using null aware operators instead:

```dart
BoxConstraints(
  minWidth: resolvedMinimumSize?.width ?? 0.0,
  minHeight: resolvedMinimumSize?.height ?? 0.0,
  maxWidth: resolvedMaximumSize?.width ?? double.infinity,
  maxHeight: resolvedMaximumSize?.height ?? double.infinity,
),
```

This solves the problem in my own code and also makes null safe for other users.
Repository: vscode
Issue: Enable picking relative files from quick open
Labels: feature-request,quick-open

<!-- ⚠️⚠️ 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. -->

For example I have that structure 

```
src/file1.ts
src/file2.ts
files.ts
```

Add specific logic for opening relative files just like from terminal.

Let's say `src/file1.ts` is open and typing `./file2.ts` in quickopen should open src/file2.ts

When user start typing `.` or `..` it should list all files in this directoy only. or in parent dir respectevily
Repository: create-react-app
Issue: when i try to deploy using npm run deploy it throws error as required file not found index.html
Labels: stale,needs triage

how to solve this please help me out

Thanks!
Repository: go
Issue: cmd/go: "help test" caching paragraph is out-of-date and potentially misleading
Labels: Documentation,NeedsInvestigation,GoCommand

First the out-of-date part: In https://github.com/golang/go/commit/c55a50edb9454dbdaca165be4b030a1e0cfbaa19 the special-casing of `-timeout` was removed, but the documentation for this behaviour at https://github.com/golang/go/blob/master/src/cmd/go/internal/test/test.go#L131 is still there.

Now the misleading: To correctly interpret "the run involves the same test binary and the flags on the command line", one has to understand some amount of the inner workings of the test process - specifically that we are talking about only those flags that are actually forwarded to the binary under test, and not all flags passed to `go test` itself. So for example `-vet` is fine to use for a cacheable run. Further, AFAIK the flags that are/aren't forwarded aren't enumerated in any documentation, or even in a single place in the code - there's a little discussion at `go help testflag` but no list.

I think the clearest way to resolve this would be to remove the flag-level detail in that paragraph, and instead explictly state the caching behaviour of each flag in `go help testflag`, i.e. "Cacheable" / "Ignored for caching" / "Prevents caching".
Repository: pytorch
Issue: How can I re-weight a sample based on both class weights and instance weights?
Labels: module: loss,triaged,enhancement

when `weight` is not None:
```
loss = F.cross_entropy(pred, target, weight=self.per_cls_weights, reduction='none').mean()
``` 
is not equal to
```
loss = F.cross_entropy(pred, target, weight=self.per_cls_weights)
```
or
```
loss = F.cross_entropy(pred, target, weight=None)
```


But  I do not know how to reweight a sample based on both class weight and sample weight, i.e.
```
class_weights  # num_classes
instance_weights  # batch_size
```
Am I doing the right thing to write this code?
```
base_loss = F.cross_entropy(pred, target, reduction='none')
final_weights = class_weights[target] * instance_weights
loss = (base_loss * final_weights).sum() / final_weights.sum()
```
Repository: flutter
Issue: [desktop]: windows: Can't replace method handler callback
Labels: platform-windows,a: platform-views,a: desktop,has reproducible steps,P2,found in release: 2.5,found in release: 2.6,team-windows,triaged-windows

I noticed, that once you've registered a callback method via `setMethodCallHandler`, you can't replace the registered callback on Windows.

Sample program: https://github.com/slimyjimmy/method_channel_bug_demo_win/tree/update_callback_doesnt_work (see readme for instructions on how to use)

Flutter doctor -v output:
[√] Flutter (Channel stable, 2.5.0, on Microsoft Windows [Version 10.0.19043.1165], locale en-US)
    • Flutter version 2.5.0 at C:\src\Flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 4cc385b4b8 (12 days ago), 2021-09-07 23:01:49 -0700
    • Engine revision f0826da7ef
    • Dart version 2.14.0

[!] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
    • Android SDK at C:\Users\nowak\AppData\Local\Android\sdk
    X cmdline-tools component is missing
      Run `path/to/sdkmanager --install "cmdline-tools;latest"`
      See https://developer.android.com/studio/command-line for more details.
    X Android license status unknown.
      Run `flutter doctor --android-licenses` to accept the SDK licenses.
      See https://flutter.dev/docs/get-started/install/windows#android-setup for more details.

[√] Chrome - develop for the web
    • Chrome at C:\Program Files\Google\Chrome\Application\chrome.exe

[√] Visual Studio - develop for Windows (Visual Studio Professional 2019 16.8.3)
    • Visual Studio at C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional
    • Visual Studio Professional 2019 version 16.8.30804.86
    • Windows 10 SDK version 10.0.18362.0

[√] Android Studio (version 2020.3)
    • Android Studio at C:\Program Files\Android\Android Studio
    • Flutter plugin can be installed from:
       https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
       https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7249189)

[√] VS Code (version 1.60.1)
    • VS Code at C:\Users\nowak\AppData\Local\Programs\Microsoft VS Code
    • Flutter extension can be installed from:
       https://marketplace.visualstudio.com/items?itemName=Dart-Code.flutter

[√] Connected device (3 available)
    • Windows (desktop) • windows • windows-x64    • Microsoft Windows [Version 10.0.19043.1165]
    • Chrome (web)      • chrome  • web-javascript • Google Chrome 92.0.4515.131
    • Edge (web)        • edge    • web-javascript • Microsoft Edge 92.0.902.73

! Doctor found issues in 1 category.
Repository: electron
Issue: [Feature Request]: non-blocking implementation of `nativeImage.createThumbnailFromPath()` for Windows
Labels: enhancement :sparkles:

### Preflight Checklist

- [X] I have read the [Contributing Guidelines](https://github.com/electron/electron/blob/master/CONTRIBUTING.md) for this project.
- [X] I agree to follow the [Code of Conduct](https://github.com/electron/electron/blob/master/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

`nativeImage.createThumbnailFromPath()` is implemented in a blocking way for Windows https://github.com/electron/electron/blob/efa70131e2b88031470f8cc4ec5a8e166c17615b/shell/common/api/electron_api_native_image_win.cc#L25

### Proposed Solution

This and all other asynchronous functions should be implemented in a non-blocking way

### Alternatives Considered

None

### Additional Information

_No response_
Repository: rust
Issue: Documentation for `fetch_update` talks about success and failure orderings, but the arguments are for fetch and store orderings
Labels: A-docs

They may be the same but when you read

```
pub fn fetch_update<F>(&self, set_order: Ordering, fetch_order: Ordering, f: F) -> Result<usize, usize> where F: FnMut(usize) -> Option<usize>, 
```

(note `set/fetch_order`), the two paragraphs that talk about the operation ordering don't make all that much sense. We should either rename the arguments accordingly or adjust the documentation to talk about `set` and `fetch` orderings instead.
Repository: neovim
Issue: Lua: integrate LuaJit "blob" type (string buffer)
Labels: enhancement,vimscript,lua,core

newer LuaJit introduceds a "String Buffer" (ext_buffer) concept: https://github.com/LuaJIT/LuaJIT/commit/a119497becdf2894fb7fa737f106464309dd7947

[docs](https://github.com/LuaJIT/LuaJIT/blob/a119497becdf2894fb7fa737f106464309dd7947/doc/ext_buffer.html)

> The string buffer library allows high-performance manipulation of string-like data.
>
> Unlike Lua strings, which are constants, string buffers are mutable sequences of 8-bit (binary-transparent) characters. Data can be stored, formatted and encoded into a string buffer and later converted, extracted or decoded.
>
> ... In conjunction with the FFI library, they allow zero-copy operations.
>
> The string buffer libary also includes a high-performance serializer for Lua objects.

can we map this to Vim "blob" type?

besides performance, it has ring-buffer behavior:

> The buffer space that holds the characters is managed automatically—it grows as needed and already consumed space is recycled. Use `buffer.new(size)` and `buf:free()`, if you need more
control.