sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: pytorch
Issue: torch.randint should accept high=2**63
Labels: triaged,module: random,module: edge cases

### 🐛 Describe the bug

It is not possible to use `torch.randint` to get random values in the range [0, 2^63-1].
That is, the non-negative integers that fit in an int64.

```
>>> torch.randint(2**63, (2,2))
RuntimeError: Overflow when unpacking long
```

This is of course because `2**63` doesn't itself fit into an int64.
However, the specification of `torch.randint` is "high (int): **One above** the highest integer to be drawn from the distribution." So it would make sense to support this "high" value to take advantage of the full range of int64 in the generated tensor.

### Versions

Collecting environment information...
PyTorch version: 1.11.0
Is debug build: False
CUDA used to build PyTorch: None
ROCM used to build PyTorch: N/A

OS: macOS 12.3.1 (x86_64)
GCC version: Could not collect
Clang version: 13.1.6 (clang-1316.0.21.2.3)
CMake version: version 3.21.4
Libc version: N/A

Python version: 3.9.13 (main, Jun 15 2022, 01:24:55)  [Clang 13.1.6 (clang-1316.0.21.2.3)] (64-bit runtime)
Python platform: macOS-12.3.1-x86_64-i386-64bit
Is CUDA available: False
CUDA runtime version: No CUDA
GPU models and configuration: No CUDA
Nvidia driver version: No CUDA
cuDNN version: No CUDA
HIP runtime version: N/A
MIOpen runtime version: N/A
Is XNNPACK available: True

Versions of relevant libraries:
[pip3] functorch==0.1.1
[pip3] numpy==1.22.4
[pip3] torch==1.11.0
[pip3] torchmetrics==0.8.2
[pip3] torchvision==0.12.0
[conda] Could not collect

cc @pbelevich
Repository: pytorch
Issue: torch.utils.checkpoint optimization opportunity
Labels: module: autograd,triaged,enhancement,has workaround

Currently checkpointing will always rerun the entirety of the forward function in backward, but sometimes that is not needed to recompute all the tensors that are needed for backward.

In the below snippet, suppose we want to avoid saving X2 for backward. With checkpointing, we'd need to checkpoint the function: `W2 @ gelu(X1)`, which would compute both gelu and matmul in backward. However, only the inputs of the last operation are saved for backward, so it is not actually necessary to compute the last matmul. The workaround for that is to use a custom function and do checkpointing manually.
```
X1 = W1 @ X
X2 = gelu(X1)
Y = W2 @ X2
```

Can we have an automated solution for this though? Some possible implementations:
1.  interpose checks (e.g. using python dispatch level) to see if we've already computed all the needed saved tensors, and early stop. We should be careful though: if we use python dispatch, we actually go through a different composite compliant specific path which changes some in-place ops to out-of-place ops. I wonder if torch_function works though.
2.  allow user to pass in a separate function(s) that are used to recompute the tensors. The issue with this is that what is saved is not really public API and subject to change.

Thanks @ngoyal2707 for reporting the issue


cc @ezyang @albanD @zou3519 @gqchen @pearu @nikitaved @soulitzer @Lezcano @Varal7
Repository: flutter
Issue: [flutter_tools] general.shard and commands.shard/hermetic are not hermetic
Labels: tool,P2,team-tool,triaged-tool

The flutter_tools test suite should pass on local development devices. However, running `dart test` in `//flutter/packages/flutter_tools` will generally lead to hundreds of failures. Especially the unit test in the `general.shard` and `commands.shard/hermetic` should be hermetic and not dependent on the environment that they are run in. These tests that pass on CI but fail locally are most likely leaking the environment state, and only coincidentally pass on CI because the environment state is correct. These tests should be updated to fake out the real environment so that the tests are reproducible locally (integration tests will always have dependencies on the system they run on).

This is an umbrella tracking issue for PRs that fix individual tests.

As part of this, we should also remove all instances of `@Tags(<string>['no-shuffle'])` from the test suite (see https://github.com/flutter/flutter/issues/85160)

edits by @andrewkolos:
* https://github.com/flutter/flutter/pull/151357
Repository: transformers
Issue: DeltaLM
Labels: New model

### Model description

DeltaLM is a multilingual encoder-decoder architecture that regards the decoder as the task layer of off-the-shelf pre-trained encoders. This architecture introduces an interleaved decoder, which has a more consistent structure with the encoder. Weights from pre-trained multilingual encoders are used to initialise both the encoder and decoder models before training on monolingual and bilingual data.

As of September 2021 DeltaLM ranks first on the [WMT21 multilingual translation task](http://www.statmt.org/wmt21/large-scale-multilingual-translation-task.html).

### Open source status

- [X] The model implementation is available
- [X] The model weights are available

### Provide useful links for the implementation
The model implementation is available at: 
https://github.com/microsoft/unilm/tree/master/deltalm

Model weights are available:
[DeltaLM-base](https://deltalm.blob.core.windows.net/deltalm/deltalm-base.pt)
[DeltaLM-large](https://deltalm.blob.core.windows.net/deltalm/deltalm-large.pt)

Who are the authors:
@shumingma @gitnlp

I'd be happy to try work on contributing the model.
Repository: tauri
Issue: [feat] bindings for different languages/runtimes
Labels: type: feature request,priority: 3 low

### Describe the problem

Python is used in almost every industry, easy to use

When will python be supported as a backend language, I am very much looking forward to that day.

### Describe the solution you'd like

python as backend language

### Alternatives considered

_No response_

### Additional context

_No response_
Repository: PowerToys
Issue: PowerToys Run: OneNote plugin not loading
Labels: Issue-Bug,Product-PowerToys Run,Needs-Triage,Run-Plugin,Needs-Team-Response

### Microsoft PowerToys version

0.60.1

### Running as admin

- [X] Yes

### Area(s) with issue?

PowerToys Run

### Steps to reproduce

OneNote Plugin is not loading.
Immediately after turning on the OneNote Plugin the error message pops up:
![image](https://user-images.githubusercontent.com/20878157/178907926-ec3959bc-e947-4761-b721-a7700dae70fa.png)

Bug Report: [PowerToysReport_2022-07-14-07-38-16.zip](https://github.com/microsoft/PowerToys/files/9108840/PowerToysReport_2022-07-14-07-38-16.zip)



### ✔️ Expected Behavior

_No response_

### ❌ Actual Behavior

_No response_

### Other Software

_No response_
Repository: flutter
Issue: The screen shrinks when the keyboard pops up in Chrome OS 
Labels: a: text input,framework,f: material design,platform-chromebook,team-design,triaged-design

We are facing issue which is that the screen shrinks when the keyboard pops up in Chrome OS making the screen unresponsive and unusable . The issue is also occurring in the text field section of the flutter gallery [Flutter Gallery](https://gallery.flutter.dev/#/demo/text-field)

[Sample Video](https://user-images.githubusercontent.com/108711688/178908974-de25a7c4-d9da-41bc-b61a-8bdd5f86bc27.mp4)
Repository: flutter
Issue: DropdownButton's menu position doesn't update on MediaQuery changes
Labels: framework,f: material design,has reproducible steps,P2,workaround available,found in release: 3.7,found in release: 3.11,team-design,triaged-design

_Originally posted by @LasseRosenow in https://github.com/flutter/flutter/issues/22075#issuecomment-549048926_

> It's not perfect though..

> As you can see:
<img src="https://user-images.githubusercontent.com/10547444/68072410-bfb07100-fd85-11e9-8edb-648f18d412e9.jpg" width ="300"> 

> The dropdown stays open, but the position of the popup changes as the keyboard closes... so the position of the dropdown is weird.
Repository: pytorch
Issue: Missing corner case handling in ATen ctc_loss implementation
Labels: module: loss,module: error checking,triaged

The current ctc_loss implementation seems not to handle the case when input_length=0. In this case, the loss should be 0 if target_length=0 or -infinity otherwise, by definition.

Moreover, if max_input_length=0, the following code snippet might cause an index out-of-range bug.

https://github.com/pytorch/pytorch/blob/62f1ff23fbf9e8f1281c135aadb3af87d2d69e7e/aten/src/ATen/native/LossCTC.cpp#L114-L117
Repository: storybook
Issue: How to configure can modify the text marked in the following figure?
Labels: feature request,needs triage

**How to configure can modify the text marked in the following figure?**
<img width="889" alt="image" src="https://user-images.githubusercontent.com/43572671/178926740-06da0265-e742-4b06-b7b0-be0b94859e54.png">
Repository: pytorch
Issue: [JIT] Request Constant Propagation to keep fake_quantize_per_tensor_affine and fake_quantize_per_channel_affine on the graph
Labels: oncall: jit

### 🚀 The feature, motivation and pitch

We are using [torch-blade](https://github.com/alibaba/BladeDISC) to accelerate  torchscript with TensorRT backend. And we are going to support Quantization-aware-training model with torch-blade and compile the subgraph to TensorRT INT8 engine. During the optimization process, we will first export the QAT-model to torchscript with fake quant (`aten::fake_quantize_per_tensor_affine` and `aten::fake_quantize_per_channel_affine`). Then the torchscript will be converted to onnx graph with fake quant (onnx::QuantizeLinear and onnx::DeQuantizedLinear). TensorRT would parse the onnx model and build the int engine.

To simplify the torchscript and make more nodes optimized by trt, we would use some jit passes to optimize the torchscript with fake-quant. However, the `aten::fake_quantize_per_tensor_affine` and `aten::fake_quantize_per_channel_affine` would be folded by `torch._C._jit_pass_constant_propagation`:

Given a graph like:
```
weight -> fake_quant -> aten::convolution
```
After `torch._C._jit_pass_constant_propagation`, the graph would be:
```
weight -> aten::convolution
```

However, the TensorRT recommends that there should be a q-dq onnx node pair in the graph for the weight(see [here](https://docs.nvidia.com/deeplearning/tensorrt/developer-guide/index.html#qdq-placement-recs))

So is that possible to add `aten::fake_quantize_per_tensor_affine` and `aten::fake_quantize_per_channel_affine` to the skip_list of `torch._C._jit_pass_constant_propagation` or provide an interface to customize the skip_list

The aten::dequantize has been added to the skip_list of `torch._C._jit_pass_constant_propagation`. see #63991


### Alternatives

_No response_

### Additional context

_No response_
Repository: PowerToys
Issue: Fancyzones user defined default layout
Labels: Idea-Enhancement,Product-FancyZones,Needs-Triage

### Description of the new feature / enhancement

Allow the user to define which layout is used as the default layout.

Currently, the default is the 3-column priority grid and this is not configurable by the user.

### Scenario when this would be used?

I am running Powertoys on my laptop. I work in a flex office environment. This means that I am constantly using different monitors, causing Fanzyzones to use the default layout (3-column priority grid). I don't like the default.

If I can set the default layout, I don't have to fix the Fanzyzones config every time I plug my laptop in at work.

It would also reduce the impact of Fancyzones reverting to the default because of errors/bugs/etc. There are a bunch of issues related to reverting to default. It will not fix everything, but I think it would make those kinds of issues less impactful. Some examples: #10334 #19350 #18185

### Supporting information

_No response_
Repository: neovim
Issue: flicker if plugin sets 'background' during startup
Labels: bug,display,startup

### Neovim version (nvim -v)

v0.7.2

### Vim (not Nvim) behaves the same?

no, vim 9.0.0

### Operating system/version

Arch Linux

### Terminal name/version

wezterm nightly

### $TERM environment variable

xterm-256color

### Installation

Arch Linux community repo

### How to reproduce the issue

- Have a terminal emulator with light colorscheme
- Source a plugin that sets `background=light` as soon as the `plugin/pluginname.vim` is sourced
- Once nvim is started, the screen flickers briefly because neovim assumes `background=dark` and renders the UI before the plugin is sourced.

If we set `background=light` in `init.vim`, then we set it early enough before nvim renders anything. But it's not possible to do that from a plugin (without calling the plugin from `init.vim`), because the plugin is sourced too late in the startup process: nvim already shows the UI before sourcing it, while normal vim does not (so the problem does not occur with normal vim).

See the attached video for a visual explanation:
- neovim is on the left: Flickers visibly
- vim is on the right: Does not flicker

https://user-images.githubusercontent.com/21310755/178955503-66796c13-79ac-4e4b-8399-fd17b177194b.mp4

Minimal example `myplugin/plugin/myplugin.vim` (`myplugin` needs to be in `rtp`):
```vim
" myplugin.vim
set background=light
```



### Expected behavior

neovim renders with `background=light` immediately, like vim does

### Actual behavior

neovim renders with `background=dark`, then sources the plugin, rerenders with `background=light` causing a visible flickering
Repository: material-ui
Issue: [ScopedCssBaseline] Style injection order changing when passing dynamic sizing.
Labels: support: question

### Duplicates

- [X] I have searched the existing issues

### Latest version

- [X] I have tested the latest version

### Current behavior 😯

For reference please see this reproducer - [codesandbox](https://codesandbox.io/s/continuousslider-demo-material-ui-forked-i7dbn3)

I have created two themes - `theme1 (spacing - 4)` and `theme2 (spacing 2)`. I have rendered MUI Sliders in each of the themes wrapped under `ScopedCssBaseline`. In each theme, I have added custom scrollbar style by overriding the styles of ScopedCssBaseline. In custom scrollbar, I am passing `minHeight` css property which is dynamic in nature and dependent on the spacing factor in each theme. 

The issue is that when I am rendering two Sliders one wrapped under in each theme and ScopedCssBaseline, I am seeing differences in slider track heights. On looking further into the issue, I found that it is happening because of the change in order of style applied by ScopedCssBaseline in each one of the slider.

**Styling order in first slider:**

![image](https://user-images.githubusercontent.com/31355903/178923221-c194ab8e-6906-4d7d-938a-0ee338d68b51.png)

**Styling order in second slider:**

![image](https://user-images.githubusercontent.com/31355903/178923742-35723e86-f8e1-472d-9819-f0bc31f17c90.png)

Due to the change in order, box-sizing property is getting overridden causing Slider track height to shrink. If we will give `minHeight` in customScollbar as static value as `50px` the issue goes away.

As suggested in https://github.com/mui/material-ui/issues/20461, I am also importing `ScopedCssBaseline` at first, but still the order is changing.



### Expected behavior 🤔

Ideally both sliders should have same track height.

### Steps to reproduce 🕹

Steps:

1. Visit codesandbox reproducer - https://codesandbox.io/s/continuousslider-demo-material-ui-forked-i7dbn3
2. See second slider and notice the track height. It will be less than the first one. Ideally both should be same.
3. Change `minHeight` in customScrollbar style to `50px` and the issue will be resolved.

So it looks adding dynamic sizing changes the style injection order.


### Context 🔦

I am trying to showcase component's look and feel for all custom themes in a single page for better comparison.

### Your environment 🌎

<details>
  <summary><code>npx @mui/envinfo</code></summary>

```
  System:
    OS: Linux 3.10 Red Hat Enterprise Linux Server 7.9 (Maipo)
  Binaries:
    Node: 16.13.0 
    Yarn: 1.22.11 
    npm: 7.23.0 
  Browser:
    Chrome: 103.0.5060.114 (Official Build) (64-bit)
  npmPackages:
    @emotion/react: ^11.9.3 => 11.9.3 
    @emotion/styled: ^11.9.3 => 11.9.3 
    @mui/icons-material: ^5.8.4 => 5.8.4 
    @mui/lab: 5.0.0-alpha.87 => 5.0.0-alpha.87 
    @mui/material: ^5.8.5 => 5.8.6 
    @mui/types:  7.1.3 
    @types/react: ^17.0.6 => 17.0.45 
    react: ^17.0.0 => 17.0.2 
    react-dom: ^17.0.2 => 17.0.2 
    typescript:  4.7.4
```
</details>
Repository: go
Issue: x/vuln/cmd/govulncheck: provide an option to scan multiple binaries in a directory
Labels: NeedsInvestigation,FeatureRequest,UX,vulncheck or vulndb

Would be nice if it provides an option to scan multiple binaries easily.

I wanted to check all the binaries in my GOPATH/bin/* as I usually do with `go version .`.

I can see `govulncheck .` or `govulncheck *` can be tricky since 
the command switches to the binary scan mode if the arg refers to an executable.
If that's complicated, providing a flag or subcommand to allow users to explicitly select the binary scanning mode is an option.
Repository: neovim
Issue: API:  formal secure "quit" function
Labels: enhancement,api



Currently there is no quit api in neovim. Clients (mostly qui) has to execute a ":qa" command in order to securely quit without data loss (for example user closed window using mouse but there are unsaved changes in some files) and there is no event that reports it is safe to quit. What I want is an ```nvim_try_quit``` (or similar name) api function which does same thing with ":qa" and a way to tell to the client that neovim is closed itself.
https://github.com/neovim/go-client/issues/139
Repository: material-ui
Issue: [material] Add `variant` prop type in all components
Labels: new feature,design: material,discussion,package: material-ui

### Duplicates

- [X] I have searched the existing issues

### Latest version

- [X] I have tested the latest version

### Current behavior 😯

Creating a List [component variant](https://mui.com/material-ui/customization/theme-components/#creating-new-component-variants) causes TypeScript errors when using the `variant` prop in the `variants` declaration or at the component usage site. 

Suppressing the TypeScript errors allows the variant to be declared and used as expected.

<img width="949" alt="Screen Shot 2022-07-14 at 14 52 39" src="https://user-images.githubusercontent.com/7543552/178979518-00638eb9-f204-4a4d-9e6f-a157c62b00d5.png">



### Expected behavior 🤔

Creating a List [component variant](https://mui.com/material-ui/customization/theme-components/#creating-new-component-variants) is supported in TypeScript.

`ListProps` should have a declaration for `variant`, like we have in `ButtonProps`:

```tsx
    /**
     * The variant to use.
     * @default 'text'
     */
    variant?: OverridableStringUnion<
      'text' | 'outlined' | 'contained',
      ButtonPropsVariantOverrides
    >;
```

### Steps to reproduce 🕹

Steps:

1. Create a [component variant](https://mui.com/material-ui/customization/theme-components/#creating-new-component-variants) for List using TypeScript.
 
[CodeSandbox](https://codesandbox.io/s/list-variant-bug-5fqdfp?file=/src/App.tsx)



### Context 🔦

We're maintaining a UI library built on top of MUI, and we want to provide a "bordered" List variant for our users. This is is blocking us from doing that.

### Your environment 🌎

_No response_
Repository: flutter
Issue: [Android]App can't be installed on a physical device
Labels: e: device-specific,platform-android,tool,a: build,P3,team-android,triaged-android

I created an app using `flutter create mobile`. Didn't make any changes.

When trying to install on a physical device, an error appears:
```
Error: ADB exited with exit code 1
Performing Streamed Install

adb: failed to install
/home/eugene/trashroads/mobile/build/app/outputs/flutter-apk/app.apk: Failure
[INSTALL_PARSE_FAILED_NO_CERTIFICATES: Failed to collect certificates from
/data/app/vmdl1860113220.tmp/base.apk using APK Signature Scheme v2: SHA-256 digest
of contents did not verify]
Error launching application on Mi A2 Lite.
```

`flutter doctor -v` output:
```
[✓] Flutter (Channel master, 3.1.0-0.0.pre.1652, on Ubuntu 20.04.4 LTS
    5.15.0-41-generic, locale ru_RU.UTF-8)
    • Flutter version 3.1.0-0.0.pre.1652 on channel master at
      /home/eugene/snap/flutter/common/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 5a5d021e51 (3 часа назад), 2022-07-14 05:18:06 -0400
    • Engine revision 55223fa5a3
    • Dart version 2.18.0 (build 2.18.0-283.0.dev)
    • DevTools version 2.15.0

Checking Android licenses is taking an unexpectedly long time...[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.0)
    • Android SDK at /home/eugene/Android/Sdk
    • Platform android-31, build-tools 33.0.0
    • Java binary at: /snap/android-studio/123/android-studio/jre/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.12+0-b1504.28-7817840)
    • All Android licenses accepted.

[✓] Chrome - develop for the web
    • Chrome at google-chrome

[✓] Linux toolchain - develop for Linux desktop
    • clang version 6.0.0-1ubuntu2 (tags/RELEASE_600/final)
    • cmake version 3.10.2
    • ninja version 1.8.2
    • pkg-config version 0.29.1

[✓] Android Studio (version 2021.2)
    • Android Studio at /snap/android-studio/123/android-studio
    • Flutter plugin version 69.0.2
    • Dart plugin version 212.5744
    • Java version OpenJDK Runtime Environment (build 11.0.12+0-b1504.28-7817840)

[✓] VS Code
    • VS Code at /snap/code/current
    • Flutter extension version 3.44.0

[✓] Connected device (3 available)
    • Mi A2 Lite (mobile) • 7260dd610505 • android-arm64  • Android 10 (API 29)
    • Linux (desktop)     • linux        • linux-x64      • Ubuntu 20.04.4 LTS
      5.15.0-41-generic
    • Chrome (web)        • chrome       • web-javascript • Google Chrome
      103.0.5060.53

[✓] HTTP Host Availability
    • All required HTTP hosts are available

• No issues found!
```

I know there have already been similar issues like https://github.com/flutter/flutter/issues/73658 and https://github.com/flutter/flutter/issues/72730
But none of the suggested solutions worked for me.

I've been trying to solve the problem for a week now, but I can't find a solution. I really want to develop on Flutter, but I can't even run the sample app:(

I don't understand what's the matter. Please help me.
Repository: go
Issue: net/http: provide an option to access /index.html directly without 301 redirect
Labels: NeedsInvestigation,FeatureRequest

<!--
Please answer these questions before submitting your issue. Thanks!
-->

### What version of Go are you using (`go version`)?
<pre>
$ go version
go1.18, go1.17, ...(may be all versions)
</pre>

### What did you do?
I found that https://github.com/golang/go/blob/master/src/net/http/fs.go#L590 will  redirect `/index.html` to `/` with **301** status code.

This 301 action may cause some problems for service worker's cache(https://stackoverflow.com/questions/40476938/service-worker-breaking-301-redirects)

> In order to stop 301 redirect, I had to [hack official GONIC code](https://github.com/ahuigo/go-lib/commit/1a99191d5c01cf9025136ce8ddb9668f123de05c#diff-67e8621fbb99281a50c089bae53d4874663d3d21ca5e90809ec207c070029351R44)


### What did you expect to see?
PWA(web app) could cache the `start_url:"/index.html"` (301 redirect)


### What did you see instead?
Since [Service Worker breaking 301 redirects](https://stackoverflow.com/questions/40476938/service-worker-breaking-301-redirects), my PWA app can't cache the `start_url:"/index.html"`

I think it's better to have an option an option to access `/index.html` directly without 301 redirect. (If possible, I could submit a PR)