sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: rust
Issue: Unhelpful error message "cannot satisfy `<associated_type> == _`"
Labels: C-enhancement,A-diagnostics,T-compiler,D-confusing

<!--
Thank you for filing a bug report! 🐛 Please provide a short summary of the bug,
along with any information you feel relevant to replicating the bug.
-->

I tried this code:

```rust
mod general {
    // Shorthand for getting the OperationState type of an Operation with a given Session type
    pub type StateOf<'s, A, Sess> = <A as HasOperationState<'s, Sess>>::State;

    // Shorthand for getting the Session type of an Operation
    pub type SessionOf<A> = <<A as Operation>::SessionLookup as SessionLookup>::Session;

    pub trait SessionLookup {
        type Session;
    }

    pub trait Operation: for<'s> HasOperationState<'s, SessionOf<Self>> {
        type SessionLookup: SessionLookup + 'static;
    }

    pub trait OperationState<'s, Sess> {
        fn session(&self) -> &Sess;
    }

    pub trait HasOperationState<'s, Sess> {
        type State: OperationState<'s, Sess>;
    }

    pub struct PhantomOperation<T: Operation>(pub ::std::marker::PhantomData<T>);
}

mod specific {
    use crate::general::*;

    pub struct MySession {}

    pub struct MySessionLookup {}

    impl SessionLookup for MySessionLookup {
        type Session = MySession;
    }

    pub trait MyOperationState {}

    pub trait MyExtensionTrait {}

    // This gives a compilation error:
    //
    // type annotations needed: cannot satisfy `<A as general::HasOperationState<'s, extension::MySession>>::State == _`
    impl<'s, A> MyExtensionTrait for PhantomOperation<A>
        where A: Operation<SessionLookup = MySessionLookup> + HasOperationState<'s, MySession>,
              StateOf<'s, A, SessionOf<A>>: MyOperationState,
    {

    }
}
```
Rust [playground](https://play.rust-lang.org/?version=nightly&mode=debug&edition=2018&gist=3b0c4951bd2033441d16993764f1ecfd) link.

It fails to compile on both the stable channel as well as the most recent nightly (`1.48.0-nightly (2020-09-17 f3c923a13a458c35ee26)`) with this error message:
```
type annotations needed: cannot satisfy `<A as general::HasOperationState<'s, extension::MySession>>::State == _`
```

I'm not sure if this code should compile without errors, but I certainly think the compiler should give a more helpful error message. The statement `<A as general::HasOperationState<'s, extension::MySession>>::State == _` seems trivial to satisfy, so it is unclear what the compiler is having trouble with.
Repository: flutter
Issue: VideoElement doesn't resume autoplay on route pop
Labels: engine,e: embedder,platform-web,has reproducible steps,P2,found in release: 3.3,found in release: 3.5,team-web,triaged-web

Inserting a VideoElement with autoplay attribute set to true in a widget produce a weird behaviour when navigating to a second route and navigating back.

## Steps to Reproduce

You can find a concrete sample in this repository: https://github.com/carlo-lucera-3r/flutter_web_video_test

Clone the sample repository and on the terminal use `flutter run -d chrome`

On run you will find a video and a button, clicking on a button will send you to a second page with only a text

#### Expected result:
Going back the video should continue to play

#### Actual result:
Going back the video doesn't restart

<details>
  <summary>Logs</summary>

```
[✓] Flutter (Channel dev, 1.22.0-1.0.pre, on Linux, locale en_US.UTF-8)
    • Flutter version 1.22.0-1.0.pre at /home/carlo/flutter
    • Framework revision ce40de69b7 (4 weeks ago), 2020-08-20 07:31:50 -0700
    • Engine revision 81027ab0cc
    • Dart version 2.10.0 (build 2.10.0-45.0.dev)

[!] Android toolchain - develop for Android devices
    • Android SDK at /usr/lib/android-sdk
    ✗ Unable to locate Android SDK.
      Install Android Studio from: https://developer.android.com/studio/index.html
      On first launch it will assist you in installing the Android SDK components.
      (or visit https://flutter.dev/docs/get-started/install/linux#android-setup for detailed instructions).
      If the Android SDK has been installed to a custom location, set ANDROID_HOME to that location.
      You may also want to add it to your PATH environment variable.

    ✗ No valid Android SDK platforms found in /usr/lib/android-sdk/platforms. Directory was empty.
    • Try re-installing or updating your Android SDK,
      visit https://flutter.dev/docs/get-started/install/linux#android-setup for detailed instructions.

[✓] Chrome - develop for the web
    • Chrome at google-chrome

[!] Android Studio (not installed)
    • Android Studio not found; download from https://developer.android.com/studio/index.html
      (or visit https://flutter.dev/docs/get-started/install/linux#android-setup for detailed instructions).

[✓] Connected device (2 available)
    • Web Server (web) • web-server • web-javascript • Flutter Tools
    • Chrome (web)     • chrome     • web-javascript • Google Chrome 84.0.4147.125

```

</details>
Repository: ant-design
Issue: Add overscroll-behavior: contain by default to table with horizontal scrolling to prevent unwanted navigation
Labels: help wanted,Inactive

- [x] I have searched the [issues](https://github.com/ant-design/ant-design/issues) of this repository and believe that this is not a duplicate.

### What problem does this feature solve?
Unwanted navigation to prev/next page in Macs Chrome on edge of horizontal scrolling.

### What does the proposed API look like?
Just add style to .ant-table-body according to https://stackoverflow.com/a/60385432/506954


<!-- generated by ant-design-issue-helper. DO NOT REMOVE -->
Repository: pytorch
Issue: Clarify use of GLog/GFlags
Labels: module: dependency bug,module: build,triaged,small,module: build warnings,better-engineering

## 🐛 Bug

The CMakeLists.txt contains https://github.com/pytorch/pytorch/blob/b85568a54a9c60986235ad1e0cc5dffc71b9d5b1/CMakeLists.txt#L756-L761 which basically says that PyTorch requires GLog and GFlags. However I just downloaded the "official pytorch" via `pip install torch==1.6.0+cpu torchvision==0.7.0+cpu -f https://download.pytorch.org/whl/torch_stable.html` and checked that glog is not used there. 

I.e. `torch/include/c10/macros/cmake_macros.h` contains `/* #undef C10_USE_GLOG */` and the cmake config string in torch/include/caffe2/core/macros.h confirms that too

This matches what @lw reported. See discussion in https://github.com/pytorch/pytorch/issues/41474#issuecomment-693344746

Is the warning message from CMake outdated? If so since when? Is that a mistake?

In particular I'd like to ask if using GLog is recommend, required and/or tested.

Background of my question is that I'm compiling PyTorch on POWER and seeing failures when using GLog due to floating point exceptions getting enabled without being able to tell why.

cc @malfet @seemethere @walterddr
Repository: flutter
Issue: InteractiveViewer should allow full-screen overlay zooming
Labels: c: new feature,framework,P3,team-framework,triaged-framework

### Describtion
InteractiveViewer widget is not working as I expected, because it not covering the other widget on my screen when I zoom in.
but instead, it zooms in below the other widgets.
I think it should be at the top of the screen.
Also, It should provide the ability to hide the status bar and the navbar while using it like Instagram as an example.

### Expected result
![20200918_135824](https://user-images.githubusercontent.com/30933932/93595343-e08eae80-f9b7-11ea-9ee5-3a5da9bdd062.gif)

### Actual result
![20200918_135744](https://user-images.githubusercontent.com/30933932/93595547-3fecbe80-f9b8-11ea-9701-4cd8497f5b00.gif)
Repository: rust
Issue: Bulk-initialization of contiguous enums with memset
Labels: I-slow,C-enhancement,T-compiler

In the Fuchsia project, we have some structs that have large numbers of contiguous `Option` fields:
```
#[derive(Debug, PartialEq)]
pub struct Example {
    pub a: Option<i8>,
    pub b: Option<i8>,
    pub c: Option<i32>,
    ...
}
```

This struct is initialised with each field set to `None`.
```
impl Example {
  pub fn empty() -> Self {
     Self {
       a: None,
       b: None,
       c: None,
       ...
     }
  }
}
```

The instructions that are generated set the "variant" portion of the Option's data to 0, but don't set the rest of the Option's data.
```
mov %rdi, %rax
xor %ecx, %ecx. 
movb  %cl, (%rdi)        // Set a's enum variant to 0
movb  %cl, 0x2(%rdi).    // Set b's enum variant to 0
...
```

It seems that if the entire enum data is allowed to be zero-initialized, rather than just the variant portion then this could be replaced with a single `memset()`.

For large-enough structs, the cost of individually setting these bytes to zero can be costly.

/cc @tmandry
Repository: godot
Issue: NetBSD DNS resolution for type IP_ANY always return IPV6 (AI_ADDRCONFIG not working).
Labels: bug,platform:linuxbsd,topic:network

**Godot version:**
Godot 3.2.x git


**OS/device including version:**
NetBSD 9 AMD64


**Issue description:**
I am given an error about trying to connect to the asset server. I don't know if this is a NetBSD issue or a godot issue.


**Steps to reproduce:**
Compile the 3.2.x git on NetBSD and watch the output in xterm. It loads fine, but gives an error about not being able to connect to the asset server.

ERROR: connect_to_host: Connection to remote host failed!
At: core/io/stream_peer_tcp.cpp:94.
Repository: react
Issue: Bug: input[type="radio"] controlled value can get out-of-sync
Labels: Type: Bug,Component: DOM,Status: Unconfirmed


React version: 16.13.1 and 17.0.0-alpha.0-2d131d782

## Steps To Reproduce

1. Render two `input[type="radio"][name="radio"]`: one is checked, one isn't
2. Get warning about passing `onChange` or `readOnly`
3. Add empty `onChange` to both

Link to code example:

- [React 16 repro](https://codesandbox.io/s/react-16-radio-cannot-be-read-only-z9ldc)
- [React 17 repro](https://codesandbox.io/s/react-17-radio-cannot-be-read-only-forked-r6m9r)
- [React 18 repro](https://codesandbox.io/s/react-18-radio-cannot-be-read-only-forked-7j9ckd)

## The current behavior

![screencapture of the described behavior](https://i.ibb.co/CMGcrSH/react-readonly-radio.gif)

1. React recommends `readOnly` for `input[type="radio"]` even though this isn't supported natively (though React could polyfill it)
2. After looping through the radios once with arrow key navigation the checked state changes

## The expected behavior

Arrow key navigation shouldn't break out of the controlled value. It's debateable whether React should recommend `readOnly` when this isn't a standard attribute like `readOnly` for `<input type="text" />`.
Repository: vscode
Issue: Buttons and commands associated with a custom editor are gone under a certain scenario
Labels: bug,webview,custom-editors

<!-- ⚠️⚠️ Do Not Delete This! bug_report_template ⚠️⚠️ -->
<!-- Please read our Rules of Conduct: https://opensource.microsoft.com/codeofconduct/ -->
<!-- Please search existing issues to avoid creating duplicates. -->
<!-- Also please test using the latest insiders build to make sure your issue has not already been fixed: https://code.visualstudio.com/insiders/ -->

<!-- Use Help > Report Issue to prefill these. -->
- VSCode Version: 1.49.1
- OS Version: Ubuntu 20.04.1 LTS

Buttons and commands associated with a custom editor are gone 
if you define a language in the `package.json` and a different file association in the `settings.json`.

You can reproduce this issue by doing the following changes on the [custom-editor-sample](https://github.com/microsoft/vscode-extension-samples/tree/master/custom-editor-sample):

1. Add these contribution points in the `package.json`
```json
"menus": {
  "commandPalette": [
    {
      "when": "resourceLangId == pawDraw",
      "command": "catCustoms.pawDraw.new"
    }
  ],
  "editor/title": [
    {
      "when": "resourceLangId == pawDraw",
      "command": "catCustoms.pawDraw.new",
      "group": "navigation"
    }
  ]
},
"languages": [
  {
    "id": "pawDraw",
    "extensions": [
      ".pawDraw"
    ],
    "aliases": [
      "pawDraw"
    ]
  }
]
```

2. Add this config in your `settings.json`
```json
"files.associations": {
    "*.pawDraw": "xml"
}
```

Since the custom editor works fine even with this file association, 
I'd expect commands/buttons associated with this custom editor working fine as well.
Please let me know if this behavior is expected or if this is indeed a bug.

See:
![pawDraw](https://user-images.githubusercontent.com/638737/93601923-453a1100-f998-11ea-850a-b431b44a0471.gif)

/cc @mjbvz
Repository: vscode
Issue: Slow reponse to scroll and typing
Labels: bug,accessibility,windows,perf,mitigated


Issue Type: <b>Performance Issue</b>

It is not slow to start-up, it is slow to do anything in the text editor (scroll, find, type, etc). For example, when scrolling, the screen is unable to keep up with the mouse wheel and it will keep scrolling for a while after I stop the mouse wheel. I disabled the extensions I installed lately, and also reduced the amount of files in the workspace. 

VS Code version: Code 1.49.1 (58bb7b2331731bf72587010e943852e13e6fd3cf, 2020-09-16T23:27:51.792Z)
OS version: Windows_NT x64 10.0.19041

<details>
<summary>System Info</summary>

|Item|Value|
|---|---|
|CPUs|Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz (4 x 2712)|
|GPU Status|2d_canvas: enabled<br>flash_3d: enabled<br>flash_stage3d: enabled<br>flash_stage3d_baseline: enabled<br>gpu_compositing: enabled<br>multiple_raster_threads: enabled_on<br>oop_rasterization: disabled_off<br>opengl: enabled_on<br>protected_video_decode: enabled<br>rasterization: enabled<br>skia_renderer: disabled_off_ok<br>video_decode: enabled<br>vulkan: disabled_off<br>webgl: enabled<br>webgl2: enabled|
|Load (avg)|undefined|
|Memory (System)|11.85GB (4.20GB free)|
|Process Argv|--crash-reporter-id 2c01e348-504e-456f-931c-280aa8926a03|
|Screen Reader|no|
|VM|0%|
</details><details>
<summary>Process Info</summary>

```
CPU %	Mem MB	   PID	Process
    2	    96	 33588	code main
    2	    88	 13340	   shared-process
    3	    84	 26656	   window (Issue Reporter)
    0	    24	 27836	   crashpad-handler
    0	   223	 30908	   window (Settings - local_svn_workspace (Workspace) - Visual Studio Code)
    0	    11	  6640	     watcherService 
    0	     6	 12092	       console-window-host (Windows internal process)
    0	     6	  9240	     console-window-host (Windows internal process)
    0	    96	 19504	     extensionHost
    0	    69	 30740	     C:\WINDOWS\System32\WindowsPowerShell\v1.0\powershell.exe
    0	    60	 30924	   utility
    1	   241	 33368	   gpu-process
```

</details>
<details>
<summary>Workspace Info</summary>

```
|  Window (Settings - local_svn_workspace (Workspace) - Visual Studio Code)
|    Folder (JESD204): 1760 files
|      File types: svn-base(998) v(161) sv(38) sh(33) tcl(30) prj(30) do(25)
|                  tmp(9) txt(9) log(7)
|      Conf files: makefile(7);
```

</details>
<details><summary>Extensions (11)</summary>

Extension|Author (truncated)|Version
---|---|---
better-comments|aar|2.1.0
bracket-pair-colorizer|Coe|1.0.61
ctags-support|jay|1.0.19
svn-scm|joh|2.12.4
rainbow-csv|mec|1.7.1
remote-ssh|ms-|0.55.0
remote-ssh-edit|ms-|0.55.0
remote-wsl|ms-|0.44.5
veriloghdl|msh|1.3.3
awesome-vhdl|puo|0.0.1
tcl|ras|0.1.0


</details>
<!-- generated by issue reporter -->
Repository: godot
Issue: Relative path script extending does not work with scripts not in res (parse error)
Labels: discussion,topic:gdscript,topic:editor,documentation

<!-- Please search existing issues for potential duplicates before filing yours:
https://github.com/godotengine/godot/issues?q=is%3Aissue
-->

**Godot version:**
<!-- Specify commit hash if using non-official build. -->
3.2.3.stable

**OS/device including version:**
<!-- Specify GPU model, drivers, and the backend (GLES2, GLES3, Vulkan) if graphics-related. -->
Windows

**Issue description:**
<!-- What happened, and what was expected. -->
Godot can extend scripts using relative paths
for example `extends "A.gd"` means extending script A.gd that is inside the same folder as the current one.
But this doesn't work with scripts not located in `res://`
the error appears `Parse Error: Couldn't resolve relative path for the parent class: B.gd`

**Steps to reproduce:**
1. create a script `A.gd` somewhere outside of `res://` with code `extends "B.gd"`
2. create a script `B.gd` in the same folder as `A.gd` with code say `var test = 1`
3. create a gdscript plugin (Project Settings - Plugins - Create) with this code:
```gdscript
tool
extends EditorPlugin

func _enter_tree():
	var a = load("D://A.gd").new()
	print (a.test)
```
my path is "D://A.gd" because I created A.gd id `D://`

make it active (maybe reopen the project as well)
Now you can see error like `A.gd:2 - Parse Error: Couldn't resolve relative path for the parent class: B.gd
`
you can also check that when changing `A.gd` code to `extends "[absolute path to B.gd]"` works

**Minimal reproduction project:**
<!-- A small Godot project which reproduces the issue. Drag and drop a zip archive to upload it. -->
Repository: flutter
Issue: FrictionSimulation produces non-sensical results with drag values of 1.0
Labels: framework,f: material design,has reproducible steps,found in release: 3.3,found in release: 3.6,team-design,triaged-design

If you supply a drag value of 1.0 the simulation instantly outputs values of infinity which seems at odds with the behavior of the other values of drag. (i.e. for drag values of < 1 the dx of the simulation converges towards 0, for drag values of > 1 the dx approaches infinity, for drag values of 1 the velocity should remain constant. ) 

## Steps to Reproduce

1. checkout this repo: https://github.com/AlabasterAxe/card_swiping_example
2. run the main.dart
3. click the "NUDGE" button

**Expected results:** The block should slide across the screen at a constant velocity.

**Actual results:** The block immediately pops to infinity.

<details>
 <summary> Additional Information </summary>

```
I ran flutter analyze and there were no issues found.
```


## flutter doctor -v output:

```
[√] Flutter (Channel stable, 1.20.2, on Microsoft Windows [Version 10.0.18363.1082], locale en-US)   
    • Flutter version 1.20.2 at C:\flutter
    • Framework revision bbfbf1770c (5 weeks ago), 2020-08-13 08:33:09 -0700
    • Engine revision 9d5b21729f
    • Dart version 2.9.1

 
[!] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
    • Android SDK at C:\Users\matth\AppData\Local\Android\Sdk
    • Platform android-29, build-tools 29.0.2
    • ANDROID_HOME = C:\Users\matth\AppData\Local\Android\Sdk
    • Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)
    ! Some Android licenses not accepted.  To resolve this, run: flutter doctor --android-licenses   

[!] Android Studio (version 4.0)
    • Android Studio at C:\Program Files\Android\Android Studio
    X Flutter plugin not installed; this adds Flutter specific functionality.
    X Dart plugin not installed; this adds Dart specific functionality.
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)

[√] VS Code (version 1.49.1)
    • VS Code at C:\Users\matth\AppData\Local\Programs\Microsoft VS Code
    • Flutter extension version 3.14.1

[√] Connected device (1 available)
    • Android SDK built for x86 (mobile) • emulator-5554 • android-x86 • Android 10 (API 29)
      (emulator)

! Doctor found issues in 2 categories.
```

</details>
Repository: pytorch
Issue: Optimization with constraints for torch.optim
Labels: feature,module: optimizer,triaged,needs research

## 🚀 Feature
The option for constraint-aware optimization techniques within torch.optim. [Sequential Quadratic Programming](https://en.wikipedia.org/wiki/Sequential_quadratic_programming) is a very common choice, but there are other algorithms out there.  

## Motivation
SQP (and related techniques) are nice for when parameters need to be within a specified range (or satify some other constraint function), such as when using optimization for solving a kinematics problem under real-world kinematic constraints. Or when optimizing a dynamic trajectory for a robot to follow such that the trajectory doesn't exceed a robot's physical limits.

## Pitch

PyTorch's optim package is quite powerful not just for neural networks, but for much more general optimization problems. The autograd functionality and it's ability to use GPU acceleration implicitly are super convenient.  However, none of the current optimization approaches in PyTorch are "constraint-aware" in the sense that the parameters you optimize can float wherever they need to in <img src="https://render.githubusercontent.com/render/math?math=\mathbb{R}^n">, where n in the dimension of whatever parameter space is being optimized, so long as that results in a smaller objective functional.  


## Alternatives

There exist [python implementations of SQP and other non-linear optimization approaches](https://docs.scipy.org/doc/scipy/reference/generated/scipy.optimize.minimize.html), but they are cpu-only and lack PyTorch's autograd functionality for computing derivatives/jacobians automatically (read: "I am too lazy to implement derivatives myself").

## Additional context
None presently identified.


cc @vincentqb
Repository: flutter
Issue: Implement auto-completion for zsh, bash, and PowerShell for the flutter tool
Labels: c: new feature,tool,P3,team-tool,triaged-tool

Rather than attempt to look up args at runtime (which cause artifacts to be downloaded or compiled), the SDK could generate a script/data format for different shells to consume and check this in during development (since the args/commands do not change frequently). This should allow completion to work provided the SDK is present, without requiring any bounces through the Dart SDK.

TBD: more details


ZSH completions: https://github.com/zsh-users/zsh-completions/blob/master/src/_flutter
Some PowerShell docs: https://docs.microsoft.com/en-us/dotnet/core/tools/enable-tab-autocomplete