sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: flutter
Issue: UI hangs on Mac M1 when calling AVFoundation's function on platform side
Labels: engine,c: performance,platform-mac,has reproducible steps,P2,found in release: 3.3,found in release: 3.7,team-engine,triaged-engine

## Details

Application's UI hangs for a couple of seconds on Apple Silicon Macs when AVFoundation's function `AVCaptureDevice.default(for: AVMediaType.video)` is called on __NOT UI thread__. This bug will appear only on first access to the media devices. So if we (or some another application) already use media device, then UI will not hang. 

Theoretically, this bug can appear on Intel Macs too, but hang is very small on it, so I can't guarantee that this bug can be easily reproduced on Intel Macs, so I recommend to use Apple Silicon Mac for reproducing.

This problem was tested on many MacBooks with M1 processors and on one Intel MacBook. All tested Macs are running MacOS Ventura (13.0).

Another theory is that this problem appeared on latest MacOS Ventura (13.0), but we don't have any Mac on older MacOS, so I can't tell exactly that this is related.

## Code which hangs UI

```swift
DispatchQueue.global(qos: .userInitiated).async {
    // Until this function is running, Flutter UI hangs
    let video = AVCaptureDevice.default(for: AVMediaType.video)
}
```

## Reproducing

__Apple Silicon Mac is required__, because this problem only appears on Macs with Apple Silicon processors.

1. `git clone https://github.com/evdokimovs/macos_flutter_bug_mvp`
2. `cd macos_flutter_bug_mvp/macos_media_test`
3. `flutter run -d macos`
4. Click on "Increment" button

Most interesting part of this example is MacOS platform code: [`macos_flutter_bug_mvp/macos_media_test_plugin/macos/Classes/MacosMediaTestPlugin.swift:17`][1]

### Bug behavior

UI thread hangs for about 1 second.

## Screen record of a bug

[test.webm](https://user-images.githubusercontent.com/49490279/206459449-d0e1f49e-2f74-4678-956d-5290e155ae05.webm)

## XCode Instruments Trace file

[hang.trace.zip](https://github.com/flutter/flutter/files/10185982/hang.trace.zip)


## Device Information

**Target Platform:** `macos`
**Target OS version/browser:** `Ventura 13.0.1`
**Devices:** `MacBook Pro 16 (2021, Apple M1 Max)`

## `flutter --version`

```
Flutter * 3.3.9 channel stable * https://github.com/flutter/flutter.git
Framework * revision b8f7f1f986 (2 weeks ago) * 2022-11-23 06:43:51 +0900
Engine * revision 8f2221fbef
Tools * Dart 2.18.5 * DevTools 2.15.0
```

[1]: https://github.com/evdokimovs/macos_flutter_bug_mvp/blob/master/macos_media_test_plugin/macos/Classes/MacosMediaTestPlugin.swift#L17
Repository: flutter
Issue: Add mouseButton attribute in ReorderableListView
Labels: c: new feature,framework,f: material design,f: scrolling,c: proposal,a: mouse,P3,team-design,triaged-design

## Use case

We want to write a reordered tab which can pop up menu when right mouse button is clicked, but it's easy to cause shaking When the right mouse button is clicked. So I need a [ReorderableListView](https://api.flutter.dev/flutter/material/ReorderableListView-class.html) which only works on left mouse button.

In this code, It's easy to print "move" when clicking right mouse button.
<details>
  <summary>Code</summary>

```
import 'package:flutter/material.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(
        primarySwatch: Colors.blue,
      ),
      home: const MyHomePage(title: 'Flutter Demo Home Page'),
    );
  }
}

class MyHomePage extends StatefulWidget {
  const MyHomePage({super.key, required this.title});

  final String title;

  @override
  State<MyHomePage> createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {
  List<Color> list = [Colors.red, Colors.green, Colors.blue];

  @override
  Widget build(BuildContext context) {
    return Scaffold(
        appBar: AppBar(
          title: Text(widget.title),
        ),
        body: Listener(
          onPointerMove: (event) => print("move"),
          child: ReorderableListView(
            scrollDirection: Axis.horizontal,
            children: [
              for (int i = 0; i < list.length; i++)
                ReorderableDragStartListener(
                  key: ValueKey(i),
                  index: i,
                  enabled: true,
                  child: Container(
                    width: 100,
                    height: 100,
                    color: list[i],
                  ),
                )
            ],
            onReorder: (int oldIndex, int newIndex) {
              setState(() {
                if (oldIndex < newIndex) {
                  newIndex -= 1;
                }
                final item = list.removeAt(oldIndex);
                list.insert(newIndex, item);
              });
            },
          ),
        ));
  }
}

```

</details>

<details>
  <summary>Gif</summary>

![hello_wgDv96JVlf](https://user-images.githubusercontent.com/14891774/206463330-5936ca71-2aae-41ba-bfb6-4b4865911d18.gif)

</details>


## Proposal

Add mouseButton attribute in [ReorderableListView](https://api.flutter.dev/flutter/material/ReorderableListView-class.html) , or add  [EventFilter](https://doc.qt.io/qt-6/qobject.html#eventFilter)  widget like Qt.
Repository: PowerToys
Issue: Universal Spatial Navigation
Labels: Needs-Triage

### Description of the new feature / enhancement

I would love to see the spatial Navigation feature some Browsers like Opera have, being implementet unversaly for any application

### Scenario when this would be used?

Day to day use to improve efficiency

### Supporting information

https://en.wikipedia.org/wiki/Spatial_navigation
Repository: terminal
Issue: Terminal closes when pwsh crashes with PSReadLine module imported after window session resume
Labels: Product-Conhost,Needs-Repro,Area-Server,Issue-Bug,Priority-3

### Windows Terminal version

 1.16.2642.0

### Windows build number

 10.0.22621.0

### Other Software

pwsh 7.3.0
PSReadLine 2.26

### Steps to reproduce

Open terminal
Open a tab with pwsh and a tab with cmd
Close lid (Surface Book 3) or get OS to sleep
Wake up and log in to session


### Expected Behavior

WT is there and all tabs are open

### Actual Behavior

WT is closed. I will add more details in the comment below.
Repository: pytorch
Issue: Saving a scripted module to a buffer does not work.
Labels: oncall: jit

### 🐛 Describe the bug

A scripted pytorch module can not be saved to a buffer. It will instead save the module to a file with the name of the buffer-object.
According to the [documentation](https://pytorch.org/docs/stable/generated/torch.jit.ScriptModule.html#torch.jit.ScriptModule.save), the following code should have saved the model to the buffer. Instead the model is written to a file with the name of the buffer's __str__ representation. The buffer remains empty.
I expected the buffer to not be empty and that no file would be made on the filesystem.

```import torch
import io

class Model(torch.nn.Module):
    def forward(self, x): 
        return x+1 

model = Model().cuda() 
traced = torch.jit.script(model, torch.ones(1, 3, 128, 128, device='cuda'))

with io.BytesIO() as buf:
    traced.save(buf)
```

### Versions



```
Collecting environment information...
PyTorch version: 1.13.0
Is debug build: False
CUDA used to build PyTorch: 11.6
ROCM used to build PyTorch: N/A

OS: Ubuntu 22.04.1 LTS (x86_64)
GCC version: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0
Clang version: Could not collect
CMake version: Could not collect
Libc version: glibc-2.35

Python version: 3.9.15 (main, Nov 24 2022, 14:31:59)  [GCC 11.2.0] (64-bit runtime)
Python platform: Linux-5.15.0-53-generic-x86_64-with-glibc2.35
Is CUDA available: True
CUDA runtime version: 11.6.124
CUDA_MODULE_LOADING set to: LAZY
GPU models and configuration: GPU 0: NVIDIA GeForce RTX 3090
Nvidia driver version: 520.61.05
cuDNN version: Could not collect
HIP runtime version: N/A
MIOpen runtime version: N/A
Is XNNPACK available: True

Versions of relevant libraries:
[pip3] numpy==1.23.4
[pip3] torch==1.13.0
[pip3] torchaudio==0.13.0
[pip3] torchvision==0.14.0
[conda] blas                      1.0                         mkl  
[conda] ffmpeg                    4.3                  hf484d3e_0    pytorch
[conda] mkl                       2021.4.0           h06a4308_640  
[conda] mkl-service               2.4.0            py39h7f8727e_0  
[conda] mkl_fft                   1.3.1            py39hd3c417c_0  
[conda] mkl_random                1.2.2            py39h51133e4_0  
[conda] numpy                     1.23.4           py39h14f4228_0  
[conda] numpy-base                1.23.4           py39h31eccc5_0  
[conda] pytorch                   1.13.0          py3.9_cuda11.6_cudnn8.3.2_0    pytorch
[conda] pytorch-cuda              11.6                 h867d48c_0    pytorch
[conda] pytorch-mutex             1.0                        cuda    pytorch
[conda] torchaudio                0.13.0               py39_cu116    pytorch
[conda] torchvision               0.14.0               py39_cu116    pytorch
```

cc @EikanWang @jgong5 @wenzhe-nrv @sanchitintel
Repository: vscode
Issue: Ambiguous unicode character decoration shows in settings.json but doesn't explain on hover
Labels: bug,unicode-highlight

![image](https://user-images.githubusercontent.com/2193314/206479533-ce092fc6-3208-4a77-bab5-1046ae5db95b.png)

```
  "terminal.integrated.wordSeparators": " ()[]{}',\"─‘’",
```

The decoration doesn't show up all the time 🤷 

![image](https://user-images.githubusercontent.com/2193314/206479811-fc64cdac-04cd-4b24-ac4b-cbd64530d24e.png)
Repository: vscode
Issue: Align primary buttons alignment
Labels: ux,under-discussion

VS Code has primary buttons.

Most often the primary button is left aligned, but sometimes it is right-aligned.

Left Aligned:
* Windows dialogs
* Notifications
* Export profile dialog

Right aligned:
* Create PR
* Comments
Repository: excalidraw
Issue: grouped elements translation issue when grid enabled
Labels: bug

Hard to describe. See screencast.

https://user-images.githubusercontent.com/16517095/206480621-193bf6ef-4c98-4d09-a155-d0581dbada75.mp4
Repository: stable-diffusion-webui
Issue: [Feature Request]: Score Jacobian Chaining: Lifting Pretrained 2D Diffusion Models for 3D Generation
Labels: enhancement,extension-request

Hi  I want to know if is possible to add sjc https://github.com/pals-ttic/sjc
It's allow to generate 3d models with stable diffusion, something I find weird it's successfully render the same image/object in different angles with sd.
Some examples and explanation here : https://pals.ttic.edu/p/score-jacobian-chaining?fbclid=IwAR3Y09eGoSlsMkk1n-NUjR-LzhDpJ4TUpx3CykrNM_8c7C8Mv7Zgn4G8qXo


.
Repository: storybook
Issue: [Feature Request]: Boolean toolbar support for toolbars add-on
Labels: feature request,needs triage

### Is your feature request related to a problem? Please describe

Currently toolbars supports adding dropdown buttons such as the follow:

```json
{
    title: 'Text Direction',
    description: 'Direction of the content flow',
    showName: true,
    defaultValue: 'ltr',
    toolbar: {
        items: [
            { value: 'ltr', title: 'ltr', right: 'left to right' },
            { value: 'rtl', title: 'rtl', right: 'right to left' },
        ],
        dynamicTitle: true,
    }
}
```

Should we want to represent this in the UI as a toggle button such as the measure or outline buttons, there does not seem to be a way using the toolbar add-on.

### Describe the solution you'd like

An option to inject a boolean item would be ideal, perhaps by simply supporting the boolean values in the items array?

Something akin to:

```json
{
    title: 'Text Direction',
    description: 'Direction of the content flow',
    showName: true,
    defaultValue: true,
    toolbar: {
        items: [
            { value: true, title: 'ltr', right: 'left to right' },
            { value: false, title: 'rtl', right: 'right to left' },
        ]
    }
}
```

### Describe alternatives you've considered

A custom add-on is certainly feasible but seems useful for more focused boolean toolbar items. Ideally, users would be able to add generic toggles to the UI on-demand as part of the core add-ons utility.

### Are you able to assist to bring the feature to reality?

yes, I can

### Additional context

If there is sufficient interest in this feature, I would be happy to contribute the update.
Repository: PowerToys
Issue: Shortcut Guide shortcut list not changing depending on locale & keyboard layout.
Labels: Issue-Bug,Product-Shortcut Guide

### Microsoft PowerToys version

0.65.0

### Installation method

GitHub

### Running as admin

Yes

### Area(s) with issue?

Shortcut Guide

### Steps to reproduce

Shortcut Guide --> Pressing the combination on the screen (Windows + Shift + Ç)

### ✔️ Expected Behavior

In my locale and keyboard layout (ca-ES and catalan keyboard) I was expecting to show the "Open Emoji panel" as Windows + . (period)

### ❌ Actual Behavior

The shortcut showed as Windows + ; (semicolon) which isn't the real keyboard mapping (in my keyboard layout, the semicolon is inserted by pressing Shift + comma)

### Other Software

_No response_
Repository: storybook
Issue: [Bug]: "Support" page: 404 error
Labels: bug,needs triage

### Describe the bug

"About your Storybook" page (http://localhost:wxyz/?path=/settings/about) has a "Support" link:

![image](https://user-images.githubusercontent.com/1198848/206492579-3d4ee771-b2d3-4629-b43c-1180440b679e.png)

This is a 404 page: https://storybook.js.org/support

### To Reproduce

_No response_

### System

_No response_

### Additional context

_No response_
Repository: vscode
Issue: Add please colors to the outline panel.
Labels: feature-request,outline

<!-- ⚠️⚠️ 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. -->
Please, add a possibility to colorize names in the outline panel. And I think that it could be cool to add possibility for adding other colors for arguments and the returning type.


![image](https://user-images.githubusercontent.com/53862745/206497492-5fabe8e3-b567-4769-a0a9-08152ec1b583.png)
Repository: material-ui
Issue: [Feature?]: Support CSS Props for createTheme
Labels: docs,package: system,customization: theme

### Duplicates

- [X] I have searched the existing issues

### Latest version

- [X] I have tested the latest version

### Summary 💡

Currently, when creating a custom theme with the `createTheme` function, you are forced to use (Typescript) traditional CSS colors:

```
MUI: Unsupported `var(--custom-css-var)` color.
The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().
```

By supporting this, MUI theme extension can allow systems that already have CSS Property themes built out without needing to do any extra work via `CssVarsProvider` unnecessarily compounding the CSS Properties in the browser.

Example of what the undesired result would cause:
```css
:root {
 --var-custom-background: #000;
}

.light {
--var-custom-background: #fff;
}

/* additional MUI props that are unnecessary */
:root {
 --mui-palette-main: #000;
 --mui-palette-dark: #000;
 --mui-palette-light: #fff;
...
}
```

This also reveals an enhancement in the MUI CSS var production from the `CssVarsProvider` API that should rewrite values vs creating multiple tokens of the same category (like the custom examples above).

### Examples 🌈

Example of desired feature:
```javascript
const theme = createTheme({
  palette: {
    primary: {
      main: 'var(--action-background)'
    },
    secondary: {
      main: 'var(--info-background)'
    }
  }
});
```

Or, even something like this:
```javascript
const theme = extendTheme({
  colorSchemes: {
      palette: {
        primary: {
          main: 'var(--action-background)',
        },
      },
  },
});
```

### Motivation 🔦

Allowing this would seamless work with apps that already have multi theme support built in and just need MUI to provide components that consume the themes. 

By continuing not to support this feature and force the current and experimental APIs will create duplicated tokens, logic, and package installation just to use predetermined themes that already work within the ecosystem (i.e. don't make us have to create custom "styled" components for every single component we use vs. adjusting the colors like above).

If I missed something in the docs, please forgive my transgression. 🙏
Repository: vscode
Issue: Editor history should include editors that open inactive
Labels: feature-request,workbench-history,keep

Type: <b>Bug</b>

Open an empty vsc instance.
Drag and drop two TXT files into VSC.
Select one of the files, press F1 and select "Compare Active File With..."

Now in the dropdown it may let you select only 1 file, which may only be the same file that is currently active.

When you switch to the second file and repeat the same thing, it should actually show both files.

After doing a comparison, the list seems to get updated, and trying the same thing on the first file will actually show all open files.

You can also do this with 3 files, in which case one of them should be missing one file to display and the other two work as expected.

VS Code version: Code 1.74.0 (5235c6bb189b60b01b1f49062f4ffa42384f8c91, 2022-12-05T16:38:16.075Z)
OS version: Windows_NT x64 10.0.22621
Modes:
Sandboxed: No

<details>
<summary>A/B Experiments</summary>

```
vsliv368:30146709
vsreu685:30147344
python383:30185418
vspor879:30202332
vspor708:30202333
vspor363:30204092
vslsvsres303:30308271
pythonvspyl392:30443607
vserr242:30382549
pythontb:30283811
vsjup518:30340749
pythonptprofiler:30281270
vshan820:30294714
vstes263cf:30335440
pythondataviewer:30285071
vscod805cf:30301675
binariesv615:30325510
bridge0708:30335490
bridge0723:30353136
cmake_vspar411:30581797
vsaa593:30376534
pythonvs932:30410667
cppdebug:30492333
vsclangdc:30486549
c4g48928:30535728
dsvsc012:30540252
azure-dev_surveyone:30548225
vsccc:30610678
pyindex848:30577860
nodejswelcome1:30587005
3biah626:30602489
gswce1:30612156
3d0df643:30613357
dbltrim-noruby:30604474
89544117:30613380
fim-prod:30623723
ejf25101:30620729

```

</details>

<!-- generated by issue reporter -->
Repository: go
Issue: x/tools/gopls: allow renaming arbitrary package paths
Labels: FeatureRequest,gopls,Tools

This issue proposes to extend gopls' package renaming feature to prompt with the full package path of the the package (rather than just the package name), and allow arbitrary edits of the package path, potentially even across module boundaries.

(aside: this feature was originally part of #56184, but is significant enough in scope to warrant its own issue).

Specifically, we should:

- [ ] Prompt with the full package path in preparerename requests.
- [ ] Validate whether an arbitrary package path move can be allowed.
- [ ] Compute the (potentially complicated) set of workspace edits to implement the package move.

The pieces of this exists in the current renaming code, but must be generalized.
Repository: kubernetes
Issue: NetworkPolicy tests for blocking north/south traffic
Labels: priority/backlog,sig/network,help wanted,good first issue,triage/accepted,area/network-policy

The NP docs point out that [NP's semantics for north/south traffic are not very clearly defined](https://kubernetes.io/docs/concepts/services-networking/network-policies/#behavior-of-ipblock-selectors):

> Cluster ingress and egress mechanisms often require rewriting the source or destination IP of packets. In cases where this happens, it is not defined whether this happens before or after NetworkPolicy processing, and the behavior may be different for different combinations of network plugin, cloud provider, `Service` implementation, etc.
> 
> In the case of ingress, this means that in some cases you may be able to filter incoming packets based on the actual original source IP, while in other cases, the "source IP" that the NetworkPolicy acts on may be the IP of a `LoadBalancer` or of the Pod's node, etc.
> 
> For egress, this means that connections from pods to `Service` IPs that get rewritten to cluster-external IPs may or may not be subject to `ipBlock`-based policies.

However, what's _not_ ambiguous is that a pod which is fully isolated for ingress should not accept E/W _or_ N/S traffic. Regardless of how the ingress/LB/cloud handles the traffic, it should end up getting blocked. (Well, unless it gets masqueraded to the pod's node IP, because then it hits that exception to the rules.)

Unfortunately we can't say the same for egress; I think we assume that a pod-to-service-IP connection will be allowed to reach kube-proxy even if the pod is fully isolated-for-egress, but we explicitly don't require that `ipBlock` policies get applied after service proxying.

Anyway, we should be able to add a test to `test/e2e/network/netpol/network_policy.go` that confirms that cluster-ingress traffic to a fully isolated-for-ingress pod is not allowed. In particular, if we create a LoadBalancer Service with `externalTrafficPolicy: Local`, and a NetworkPolicy blocking all ingress to that Service's Pods, then we should not be able to connect to the service via either the LoadBalancer IP/name or via its NodePort (on one of the correct nodes).

/sig network
/area network-policy
/priority backlog
/help
/good-first-issue