sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: opencv
Issue: cv::MatExpr to cv::Mat asan crash
Labels: bug,category: core,confirmed

### System Information

* OpenCV 4.5.5 & 4.7.0 & 4.x
* macOS Xcode 14.3 asan
* Android NDK R25c asan


### Detailed description


```
#include <opencv2/core.hpp>

int main()
{
    cv::Mat matrix(2, 3, CV_32FC1);
    cv::MatExpr expr = matrix.mul(1);
    cv::Mat mat(expr); // build with asan, crash : stack-use-after-scope
    return 0;
}
```

=================================================================
==22891==ERROR: AddressSanitizer: stack-use-after-scope on address 0x7ff7b12cd6a0 at pc 0x0001109f1e80 bp 0x7ff7b12c9e90 sp 0x7ff7b12c9660
READ of size 8 at 0x7ff7b12cd6a0 thread T0
    #0 0x1109f1e7f in __asan_memcpy+0x1af (libclang_rt.asan_osx_dynamic.dylib:x86_64h+0x46e7f) (BuildId: 756bb7515781379f84412f22c4274ffd2400000010000000000a0a0000030d00)
    #1 0x10f38e8f1 in cv::opt_AVX2::cvtCopy(unsigned char const*, unsigned long, unsigned char*, unsigned long, cv::Size_<int>, unsigned long) convert.simd.hpp:169
    #2 0x10f38afa6 in cv::opt_AVX2::cvt64s(unsigned char const*, unsigned long, unsigned char const*, unsigned long, unsigned char*, unsigned long, cv::Size_<int>, void*) convert.simd.hpp:275
    #3 0x10eda7ffd in cv::convertAndUnrollScalar(cv::Mat const&, int, unsigned char*, unsigned long) copy.cpp:109
    #4 0x10ec48ef6 in cv::arithm_op(cv::_InputArray const&, cv::_InputArray const&, cv::_OutputArray const&, cv::_InputArray const&, int, void (**)(unsigned char const*, unsigned long, unsigned char const*, unsigned long, unsigned char*, unsigned long, int, int, void*), bool, void*, int) arithm.cpp:823
    #5 0x10ec4ac35 in cv::multiply(cv::_InputArray const&, cv::_InputArray const&, cv::_OutputArray const&, double, int) arithm.cpp:991
    #6 0x10f04800e in cv::MatOp_Bin::assign(cv::MatExpr const&, cv::Mat&, int) const matrix_expressions.cpp:1427
    #7 0x10ec38442 in cv::MatExpr::operator cv::Mat() const mat.inl.hpp:3078
    #8 0x10ec38043 in main main.cpp:10
    #9 0x7ff811fef41e in start+0x76e (dyld:x86_64+0xfffffffffff6e41e) (BuildId: f22a114397323e23a8b7cbade6bb830132000000200000000100000000030d00)

### Steps to reproduce

step1. compile with asan flag
step2. run

### Issue submission checklist

- [X] I report the issue, it's not a question
- [X] I checked the problem with documentation, FAQ, open issues, forum.opencv.org, Stack Overflow, etc and have not found any solution
- [X] I updated to the latest OpenCV version and the issue is still there
- [x] There is reproducer code and related data files (videos, images, onnx, etc)
Repository: next.js
Issue: [NEXT-1151] App router issue with Framer Motion shared layout animations
Labels: linear: next

### Verify canary release

- [X] I verified that the issue exists in the latest Next.js canary release

### Provide environment information

```bash
Operating System:
      Platform: linux
      Arch: x64
      Version: #22 SMP Tue Jan 10 18:39:00 UTC 2023
    Binaries:
      Node: 16.17.0
      npm: 8.15.0
      Yarn: 1.22.19
      pnpm: 7.1.0
    Relevant packages:
      next: 13.4.1-canary.1
      eslint-config-next: 13.0.7
      react: 18.2.0
      react-dom: 18.2.0
```


### Which area(s) of Next.js are affected? (leave empty if unsure)

App directory (appDir: true)

### Link to the code that reproduces this issue

https://codesandbox.io/p/sandbox/stupefied-browser-tlwo8y?file=%2FREADME.md

### To Reproduce

I provided a larger repro for context, as it is unclear which combination of factors leads to the specific bug, although a number of other people report [the same issue](https://github.com/framer/motion/issues/1850).

### Describe the Bug

Framer Motion supports a feature called shared layout animation that automatically transitions components whose styles have changed when the container (that contains them) re-renders.

This feature appears not to be working in multiple scenarios with Next.js 13 under the app folder.

In the provided example, this feature is applied to the blue navigation highlight.

The affected container in the code sandbox is:
https://codesandbox.io/p/sandbox/stupefied-browser-tlwo8y?file=%2Flib%2Fcomponents%2FNavigation.tsx

To produce the undesired behavior, I simply applied `layoutId` as specified in the [relevant Framer Motion documentation](https://www.framer.com/motion/guide-upgrade/#shared-layout-animations) to the motion elements expected to transition.

> Framer Motion 5 removes the AnimateSharedLayout component.
> Now, you can use the layoutId prop and components will animate from one to another without the need for the AnimateSharedLayout wrapper.

I believe I also tried more explicit variations. Others have reported similar or identical issues in the [bug currently open](https://github.com/framer/motion/issues/1850) with Framer Motion.

### Expected Behavior

I expect the blue highlight to slide smoothly to its new position when the nav container re-renders.

### Which browser are you using? (if relevant)

Version 113.0.5672.63 (Official Build) (64-bit)

### How are you deploying your application? (if relevant)

Usually Vercel

<sub>[NEXT-1151](https://linear.app/vercel/issue/NEXT-1151/app-router-issue-with-framer-motion-shared-layout-animations)</sub>
Repository: godot
Issue: instances leaked at exit with AudioStreamPlayer
Labels: bug,topic:audio

### Godot version

Godot_v4.0.2-stable_linux.x86_64

### System information

Ubuntu 21.10

### Issue description

At exit, if a sound is still playing errors are displayed about leaked resources.

```
WARNING: ObjectDB instances leaked at exit (run with --verbose for details).
     at: cleanup (core/object/object.cpp:1982)
Leaked instance: AudioStreamPlaybackOggVorbis:-9222506721203714948
Leaked instance: OggPacketSequence:-9222509469982784387 - Resource path: res://bip.ogg::OggPacketSequence_7k54j
Leaked instance: AudioStreamOggVorbis:-9222508920226970498 - Resource path: res://bip.ogg
Leaked instance: OggPacketSequencePlayback:-9222506171447901057
Hint: Leaked instances typically happen when nodes are removed from the scene tree (with `remove_child()`) but not freed (with `free()` or `queue_free()`).
ERROR: Resources still in use at exit (run with --verbose for details).
   at: clear (core/io/resource.cpp:489)
Resource still in use: res://bip.ogg::OggPacketSequence_7k54j (OggPacketSequence)
Resource still in use: res://bip.ogg (AudioStreamOggVorbis)
```

It doesn't always happen, it's maybe around 50% of the time.
It happens only when launched outside of the editor using command line.

### Steps to reproduce


* Create a scene with the root node with this script:
```
extends Node


func _ready() -> void:
    # play a sound
    var asp = AudioStreamPlayer.new()
    asp.stream = load('res://bip.ogg')
    self.add_child(asp)
    asp.play()

    # quit before end of sound
    await get_tree().create_timer(0.3).timeout
    get_tree().quit()
```
* launch from command line:
```
Godot_v4.0.2-stable_linux.x86_64 -t main.tscn
```

### Minimal reproduction project

[leaking_resources.zip](https://github.com/godotengine/godot/files/11404766/leaking_resources.zip)
Repository: storybook
Issue: [Bug]: migrate csf-2-to-3 does not work for CSF1
Labels: bug,help wanted,cli,sev:S4

### Describe the bug

After executing the command, the blank line of the file is deleted without any migration modification
```
 npx storybook@latest migrate csf-2-to-3 --glob="src/**/*.stories.js"
```

pic for result
![image](https://user-images.githubusercontent.com/34363724/236420139-40db1e4e-6720-4182-9b1f-4f39b99bf093.png)
![image](https://user-images.githubusercontent.com/34363724/236420622-29b9c9b5-d4df-406f-a8d6-725f4784721d.png)



### To Reproduce

_No response_

### System

```shell
Environment Info:

  System:
    OS: macOS 12.3.1
    CPU: (10) arm64 Apple M1 Max
  Binaries:
    Node: 16.13.1 - /usr/local/bin/node
    Yarn: 1.22.19 - /opt/homebrew/bin/yarn
    npm: 8.1.2 - /usr/local/bin/npm
  Browsers:
    Chrome: 112.0.5615.137
    Firefox: 110.0.1
    Safari: 15.4
  npmPackages:
    @storybook/addon-actions: ^7.0.7 => 7.0.8
    @storybook/addon-console: ^1.2.3 => 1.2.3
    @storybook/addon-links: ^7.0.7 => 7.0.8
    @storybook/addons: ^7.0.7 => 7.0.8
    @storybook/cli: ^7.0.7 => 7.0.8
    @storybook/client-api: ^7.0.7 => 7.0.8
    @storybook/react: ^7.0.7 => 7.0.8
    @storybook/react-webpack5: ^7.0.7 => 7.0.8
    @storybook/theming: ^7.0.7 => 7.0.8
```


### Additional context

_No response_
Repository: next.js
Issue: Type is referenced directly or indirectly in the fulfillment callback of its own 'then' method.
Labels: TypeScript

### Verify canary release

- [X] I verified that the issue exists in the latest Next.js canary release

### Provide environment information

```bash
Operating System:
      Platform: linux
      Arch: x64
      Version: #1 SMP Fri Jan 27 02:56:13 UTC 2023
    Binaries:
      Node: 18.16.0
      npm: 9.5.1
      Yarn: N/A
      pnpm: 8.3.1
    Relevant packages:
      next: 13.4.1-canary.1
      eslint-config-next: N/A
      react: 18.2.0
      react-dom: 18.2.0
```


### Which area(s) of Next.js are affected? (leave empty if unsure)

App directory (appDir: true), TypeScript (plugin, built-in types)

### Link to the code that reproduces this issue

n/a

### To Reproduce

```ts
// /app/layout.tsx
export default async function Foo({ children }: PropsWithChildren) {
  return children; //         ^ Type is referenced directly or indirectly in the fulfillment callback of its own 'then' method.
}
```

### Describe the Bug

 n/a

### Expected Behavior

Shouldn't throw an error.

### Which browser are you using? (if relevant)

_No response_

### How are you deploying your application? (if relevant)

_No response_
Repository: deno
Issue: removeSync() NotFound error while folder exists when used on Network Drive on Windows
Labels: bug,windows,needs discussion

I encounter some error when trying to remove a folder on a network drive on Windows (e.g Mounted Google Drive)

````typescript
// I am on a network drive
> Deno.cwd()
"G:\\Mon Drive\\Projects"
> import { existsSync } from "https://deno.land/std@0.185.0/fs/exists.ts";
undefined
// creating a directory
> Deno.mkdirSync("new_dir");
undefined
> await Deno.writeTextFile("new_dir/hello.txt", "Hello World!");
undefined
// It is seen as existing
> existsSync('new_dir')
true
// And seen as not empty
> Deno.removeSync('new_dir')
Uncaught Error: Le répertoire n’est pas vide. (os error 145): remove 'new_dir'
    at Object.removeSync (ext:deno_fs/30_fs.js:175:7)
    at <anonymous>:2:6
// But still NotFound when I try to remove it
> Deno.removeSync('new_dir', {recursive: true})
Uncaught NotFound: Le fichier spécifié est introuvable. (os error 2): remove 'new_dir'
    at Object.removeSync (ext:deno_fs/30_fs.js:175:7)
    at <anonymous>:2:6
````

Is there some specific limitation which such Drive on Windows ? Or alternative to use ? 

```` powershell
> deno --version
deno 1.33.1 (release, x86_64-pc-windows-msvc)
v8 11.4.183.1
typescript 5.0.3
````
Repository: pytorch
Issue: torch.cuda.amp.GradScaler initialization 
Labels: triaged,module: amp (automated mixed precision)

### 🐛 Describe the bug

If I just create a scaler using the following code 

`scaler = torch.cuda.amp.GradScaler()`
 
 and do not use this `scaler` in my code, then somehow training faces issue with convergence. 
 
 I have faced it with at least 2 models. 

### Versions

I have faced this in torch-1.6, torch-1.12. 

cc @mcarilli @ptrblck @leslie-fang-intel @jgong5
Repository: opencv
Issue: Plugin Inference Engine G-API Backend
Labels: feature,category: g-api / gapi

### Describe the feature and motivation

G-API has an functionality to inference NN models by using `Inference Engine` (`OpenVINO`) framework. 
But it's should be specified during cmake by providing `-DWITH_INF_ENGINE=ON` option and path to `OpenVINO`

The idea is plugin `InferenceEngine` backend so that it can work on the system which has `openvino.dll` even though G-API was compiled without special options for that.

### Additional context

_No response_
Repository: angular
Issue: NG0912 error after migrating (to 16) multiple components with no selector
Labels: area: core

### Which @angular/* package(s) are the source of the bug?

core

### Is this a regression?

Yes

### Description

Components generated with the CLI (pre 16.x or 16.x) using `--skip-selector` result in the browser displaying NG0912 error, claiming that multiple of my components have colliding selector `ng-component`, when using Angular 16. This error is **not** present in at least 13, 14, and 15.

The components in question all look like this:
```typescript
import { Component } from '@angular/core';
@Component({
  templateUrl: './foo-with-no-selector.component.html',
  styleUrls: ['./foo-with-no-selector.component.scss'],
})
export class FooWithNoSelector{ ... some stuff }
@Component({
  templateUrl: './bar-with-no-selector.component.html',
  styleUrls: ['./bar-with-no-selector.component.scss'],
})
export class BarWithNoSelector{ ... some stuff }
```
These components are used only in Routing (or manually created as dialogs using material).
Afaik the convention for route only components was to omit `selector`. Is this change intentional or is it documented somewhere?

### Please provide a link to a minimal reproduction of the bug

_No response_

### Please provide the exception or error you saw

```true
NG0912: Component ID generation collision detected. Components 'FooWithNoSelector' and 'BarWithNoSelector' with selector 'ng-component' generated the same component ID. To fix this, you can change the selector of one of those components or add an extra host attribute to force a different ID. Find more at https://angular.io/errors/NG0912
```


### Please provide the environment you discovered this bug in (run `ng version`)

```true
Angular CLI: 16.0.0
Node: 18.16.0
Package Manager: npm 9.6.4
OS: win32 x64

Angular: 16.0.0
... animations, cdk, cli, common, compiler, compiler-cli, core
... forms, material, material-luxon-adapter, platform-browser
... platform-browser-dynamic, router

Package                         Version
---------------------------------------------------------
@angular-devkit/architect       0.1600.0
@angular-devkit/build-angular   16.0.0
@angular-devkit/core            16.0.0
@angular-devkit/schematics      16.0.0
@schematics/angular             16.0.0
rxjs                            7.8.1
typescript                      4.9.5
```


### Anything else?

_No response_
Repository: rust
Issue: [Suggestion] E0432 - could it include suggestions to add "lib" in crate-type?
Labels: A-diagnostics,T-cargo

Hi,

I am learning Rust and started [a playbook](https://gitlab.com/dannywillems/rust-playbook/-/tree/main/0002-cargo-lib-bin).

I encountered the error E0432 while trying to use a binary in a library I have just created.
I spent a bit of time to understand it was because of a missing "lib" in crate-type. I thought it was automatically added as it was in the `lib` section.
Could suggestions be added to error messages?
Repository: material-ui
Issue: [Select][base-ui][joy-ui] Option with `null` value cannot be marked as selected
Labels: discussion,component: select,package: joy-ui

### Duplicates

- [X] I have searched the existing issues

### Latest version

- [X] I have tested the latest version

### Steps to reproduce 🕹

Link to live example: https://codesandbox.io/s/elated-field-eygwhs?file=/demo.js

Steps:

1. Select the "None" option
2. Open the select again, the "None" option won't be marked as active

### Current behavior 😯

When selecting a `Option` with its `value` set to `null`, the `Select` box itself will correctly show "None" as its active value, but the dropdown will not mark the option.

There is more inconsistent and unexpected behavior too:

- When the option with `null` and opening the menu again you can now not navigate with the arrow-down key away from it. Only arrow up will move the focus to another option. Once another option is in focus the arrow keys work as expected.
- Once focus is not on the option with `null` as its value, it is now impossible to go back to `null`. While the option is still counted when navigating with the arrow keys (it takes 2 keystrokes to move from above it to below it as expected) the option itself is never in focus.

### Expected behavior 🤔

The `null` option is marked as the selected value and can be selected with keyboard navigation.

### Context 🔦

_No response_

### Your environment 🌎

<details>
  <summary><code>npx @mui/envinfo</code></summary>

```
  Don't forget to mention which browser you used.
  Output from `npx @mui/envinfo` goes here.
```
</details>
Repository: node
Issue:  [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received an instance of Buffer
Labels: fs

### Version

v20.1.0

### Platform

Linux 6.1.0-0.deb11.6-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.15-1~bpo11+1 (2023-03-16) x86_64 GNU/Linux

### Subsystem

fs

### What steps will reproduce the bug?

```console
# node
Welcome to Node.js v20.1.0.
Type ".help" for more information.
> const { access, lstat, opendir, readlink } = require('fs/promises');
undefined
> const mydir = await opendir(Buffer.from('/mydirectory'), { encoding: 'buffer' })
undefined
>  for  (const file of mydir) { console.log(file) }
Uncaught:
TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received an instance of Buffer
    at __node_internal_captureLargerStackTrace (node:internal/errors:490:5)
    at new NodeError (node:internal/errors:399:5)
    at validateString (node:internal/validators:163:11)
    at Object.join (node:path:1176:7)
    at Dir.processReadResult (node:internal/fs/dir:155:22)
    at req.oncomplete (node:internal/fs/dir:131:14)
    at FSReqCallback.callbackTrampoline (node:internal/async_hooks:130:17) {
  code: 'ERR_INVALID_ARG_TYPE'
}
```

### How often does it reproduce? Is there a required condition?

When using `{ encoding: 'buffer' }`

### What is the expected behavior? Why is that the expected behavior?

This should work like v20.0.0:

```console
> for (const file of mydir) { console.log(file) }
Dirent {
  name: <Buffer 2e 54 72 61 73 68 2d 31 30 30 30>,
  [Symbol(type)]: 2
}
Dirent { name: <Buffer 63 6f 6e 66 69 67>, [Symbol(type)]: 2 }
Dirent { name: <Buffer 63 65 72 74 73>, [Symbol(type)]: 2 }
Dirent { name: <Buffer 70 6f 6f 6c>, [Symbol(type)]: 2 }
Dirent { name: <Buffer 68 6f 73 74 73>, [Symbol(type)]: 2 }
Dirent { name: <Buffer 6c 6f 67>, [Symbol(type)]: 2 }
```

### What do you see instead?

```console
Uncaught:
TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received an instance of Buffer
    at __node_internal_captureLargerStackTrace (node:internal/errors:490:5)
    at new NodeError (node:internal/errors:399:5)
    at validateString (node:internal/validators:163:11)
    at Object.join (node:path:1176:7)
    at Dir.processReadResult (node:internal/fs/dir:155:22)
    at req.oncomplete (node:internal/fs/dir:131:14)
    at FSReqCallback.callbackTrampoline (node:internal/async_hooks:130:17) {
  code: 'ERR_INVALID_ARG_TYPE'
}
```

### Additional information

_No response_
Repository: stable-diffusion-webui
Issue: [Feature Request]: PNG Info - Add textarea to paste 'copied prompt lines/generation data', plus Select parameters to send
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 ?

By copying all the lines of a prompt which includes negative prompts and image parameters (seed, steps, CFG scale, etc.), then paste them into a textarea (e.g. in PNG info), the UI would then parse the info and send them to the other tabs. This would much easier than the double step of copying and pasting the positive lines, and then the negative prompts, and then getting parameters to match.

Also, by having checkboxes for which parameters to send, this would allow the user to just choose which parts to be sent to the generation tabs.

The prompts can be found on forums such as Discord, Reddit, and Civitai (which includes a button to Copy Generation Data). Although the forums might include images, the parameters might not be embedded in them for various reasons, like edited images or converted to other formats. I assume other users also copy and paste the prompts to learn, adapt or test Stable Diffusion, so hopefully this would be a useful feature.


### Proposed workflow

![pnginfo](https://user-images.githubusercontent.com/110883900/236445609-633b11c9-f2fa-4def-8724-679b4c1eff18.png)
1. Change PNG Info tab to include the textarea for input, and checkboxes, e.g. image above.
2. Extract the parameters from the textarea if the prompt is pasted there. I assume the extract function is already within the UI modules because it should be the same if the prompt was taken from an image.
3. Based on the checkboxes, send only the checked items to the other tabs. I suggest positive prompt, negative prompt, parameters (step, CFG scale, etc. but not seed), seed and model. 


### Additional information

_No response_
Repository: PowerToys
Issue: Keyboard Remap - Automatically generate key up event
Labels: Needs-Triage

### Description of the new feature / enhancement

Support automatically generating key up messages after a remapped key is pressed

### Scenario when this would be used?

My keyboard doesn't have the `Home` / `End` keys, but there do is a "Start Calculator" key and `Insert` key.
I'm using the key remap feature to remap those keys to `Home` and `End`:
![image](https://user-images.githubusercontent.com/2989995/236449563-a52842e2-bfed-4c46-a457-36e92be4b823.png)

However, while the `Insert`->`End` key works normally, my programs doesn't seem to receive any `WM_KEYUP` message in their Window Procedure after `Start App 2` key is pressed. And this key is when remapped, I can receive key down event for the `Home` key, but I can never receive the key up event. Calling Win32's `GetKeyState(VK_HOME) & 0x8000` is also always true after key press.

Can you provide a option to allow automatically generating key up events after a remapped key is pressed?

### Supporting information

_No response_