sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: flutter
Issue: Added 'enabled' property to RaisedButton and similar classes.
Labels: framework,f: material design,c: proposal,team-design,triaged-design

To disable a button in flutter you need to return a null to the onPress method.

This results in code something like:

```dart
RaisedButton(
        onPressed: (enabled ? onPressed : null),
        label: Text(label)
}
```
Syntactically this is ugly and when first reading the doco its not obvious how to achieve something that every other framework makes obvious.


Instead the framework should add an 'enabled' property to the button.

The syntax is then:

```dart
bool enabled;
RaisedButton(
        enabled: enabled,
        onPressed: onPressed,
        label: Text(label)
}
```
This change can be made backward compatible (onPressed still works as previously documented) but will provide much cleaner syntax going forward.

This technique should be applied to other widgets that use a similar technique.

I've also came across implementations that pass a function to the onPress. This results in some very bizarre looking code that conditionally take an action but then return null in some cases. Reading this code makes little sense when most paths don't need to return anything.

I would view the current method signature as promoting bad practices.
Repository: terminal
Issue: Fast scroll by holding down Alt while scrolling with mouse wheel
Labels: Area-Input,Area-TerminalControl,Product-Terminal,Issue-Task

# Description of the new feature/enhancement

VS Code has a great feature for scrolling using the mouse wheel. The window scrolls much faster when you hold down the Alt key. I use this all the time. 

Sometimes in Windows Terminal I am scrolling through verbose CLI output, or I want to quickly look a long way back in the terminal history. It would be great if Terminal had the same Alt+scroll-wheel behaviour.
Repository: pytorch
Issue: ATen registrable operator list
Labels: module: internals,triaged

## 🚀 Feature

Expose ATen registrable operators information in ATen operator API

## Motivation

When implementing a new out-of-source ATen backend extension for PyTorch, we find it is not easy to find out which ATen operators should be registered and implemented. Extension developer expect to work only based on PyTorch ATen operator API. But in fact, we have to distinguish operators in two cases as below, which depends on PyTorch implementation,
1.	The operator is supported by sparse backend or not. If yes, we need to register the operator for not only dense backend but also for sparse backend.
2.	Backends of the operator are bypassed at runtime or not. If bypassed, we ignore the operator, or we need register and implement the operator.
Regarding sparse or not, we have to check `native_functions.yaml`.
Regarding bypass or not, we have to check `derivatives.yaml` and generated file  `VariableTypeEverything.cpp`.

## Pitch

If PyTorch can expose two operator lists as a part of API to show “sparse or not” and “bypass or not”, the case by case analysis for ATen OP could be avoided when registering Ops for new device. One intuitive idea is to mark them in existing API, for instance of detailed ATen Op schema in `RegistrationDeclarations.h`,

`{"schema": "aten::add.Tensor(Tensor self, Tensor other, *, Scalar alpha=1) -> Tensor", "compound": "false", "bypass": "false", "sparse": "true"}`
`{"schema": "aten::add_.Tensor(Tensor(a!) self, Tensor other, *, Scalar alpha=1) -> Tensor(a!)", "compound": "false", "bypass": "false", "sparse": "true"}`
`{"schema": "aten::add.out(Tensor self, Tensor other, *, Scalar alpha=1, Tensor(a!) out) -> Tensor(a!)", "compound": "false", "bypass": "false", "sparse": "true"}`
`{"schema": "aten::batch_norm(Tensor input, Tensor? weight, Tensor? bias, Tensor? running_mean, Tensor? running_var, bool training, float momentum, float eps, bool cudnn_enabled) -> Tensor", "compound": "false", "bypass": “true", "sparse": “false"}`
Repository: pytorch
Issue: Use general ATen dispatch mechanism
Labels: module: internals,triaged

## 🚀 Feature

Use general ATen dispatch mechanism in some case, like `at::lstm`.

## Motivation

When implementing a new out-of-source ATen backend extension for PyTorch, we find it is no chance to hook whole lstm cell based on existing `at::lstm` dispatch strategy. Our backend gets bad performance here.

In detail, backends of `at::lstm` are bypassed at runtime. `VariableType::lstm` calls `TypeDefaultType::lstm` directly, bypasses `c10::dispatcher`. Except for two backends, cudnn and mimopen, which are dispatched by hard-code “if-else”, others backends fall down to component operators, like `at::matmul`, `at::sigmoid`, `at::tanh`...

```
// TypeDefault::lstm -> at::native::lstm
at::native::lstm() {
  if (at::cudnn_is_acceptable(_input)) {
    ...
    return at::_cudnn_rnn();
  }
  if (at::use_miopen(_input, dropout_p)) {
    ...
    return at::miopen_rnn();
  }
  lstm_default_impl(); // fall down to component Ops, at::matmul, at::tanh...
}
```

We also find same issue in `at::_embedding_bag_backward`.

## Pitch

`at::convolution_overrideable`, `at::native_batch_norm` and `at::native_layer_norm` are good examples in similar case.
Repository: You-Dont-Know-JS
Issue: Scopes & Closures Ch. 6 - Switch Statement Scoping
Labels: errata

**Please type "I already searched for this issue":**
I already searched for this issue.

**Edition:** (1st or 2nd)
2nd

**Book Title:**
Scope & Closures

**Chapter:**
Chapter 6: Limiting Scope Exposure

**Section Title:**
Scoping with Blocks

**Problem:**
> The `{ .. }` curly-brace pair on a `switch` statement (around the set of `case` clauses) does not define a block/scope.

As best I can tell, the switch statement curly-braces referred to **do** create a scope with `const` or `let`.

For example, with `var`, foo outputs `'foo'` as expected.

```javascript
switch (true) {
  case true:
    var foo = 'foo';
}
console.log(foo);
```

However, with `let`, logging `foo` produces a reference error. (Not expected if these braces aren't creating a scope)

```javascript
switch (true) {
  case true:
    let foo = 'foo';
}
console.log(foo);
```

This came up in our last online Code Club discussion (which I believe you have visited previously). Thanks so much for providing this resource!
Repository: fastapi
Issue: Improve `HTTPDigest` implementation
Labels: feature,confirmed,reviewed

### Describe the bug

`fastapi.security.HTTPDigest` is actually not implementing HTTP Digest Access Authentication as specified by [RFC 7616](https://tools.ietf.org/html/rfc7616) or (the obsoleted) [RFC 2617](https://tools.ietf.org/html/rfc2617).

### To Reproduce

Read the relevant RFCs or maybe try it out using `curl --digest`.

### Expected behavior

Exactly as specified in [RFC 7616](https://tools.ietf.org/html/rfc7616).
Repository: flutter
Issue: Define a standard performance timing module, include the first-paint, first-contentful-paint, Time to Interactive in the flutter
Labels: engine,c: performance,platform-web,c: proposal,perf: speed,e: web_canvaskit,P3,team-web,triaged-web

<!-- Thank you for using Flutter!

     If you are looking for support, please check out our documentation
     or consider asking a question on Stack Overflow:
      * https://flutter.dev/
      * https://api.flutter.dev/
      * https://stackoverflow.com/questions/tagged/flutter?sort=frequent

     If you have found a bug or if our documentation doesn't have an answer
     to what you're looking for, then fill our the template below. Please read
     our guide to filing a bug first: https://flutter.dev/docs/resources/bug-reports
-->

## Use case
It's very important to know the performance data on the phone of the user, especially when the app is released.
There is the frame timing to calculate the fps data of the page, but we don't have any way to know the performance cost of the page opening on the flutter, like the first paint, time to interactive...

<!--
     Please tell us the problem you are running into that led to you wanting
     a new feature.

     Is your feature request related to a problem? Please give a clear and
     concise description of what the problem is.

     Describe alternative solutions you've considered. Is there a package
     on pub.dev/flutter that already solves this?
-->

## Proposal
we can calculate the the first paint timing when the first frame event is called back, but it's hard to know the time to interactive of the page. 
on the web, time to interactive is defined like this:

Time to Interactive (TTI) is a page load performance metric that measures how long it takes for a web page to become interactive, which is defined as the point where:

1. The page has displayed useful content
2. Event handlers are registered for most visible page elements
3. When a user interacts with the page, the page consistently responds within 50ms - the user does not experience jank.
 (-- from https://github.com/WICG/time-to-interactive)

so, is there any way to define a standard performance timing module, include the first-paint, first-contentful-paint, Time to Interactive in the flutter per page?
(follow the w3c standard : https://w3c.github.io/paint-timing/#first-paint)

<!--
     Briefly but precisely describe what you would like Flutter to be able to do.

     Consider attaching images showing what you are imagining.

     Does this have to be provided by Flutter directly, or can it be provided
     by a package on pub.dev/flutter? If so, maybe consider implementing and
     publishing such a package rather than filing a bug.
-->
Repository: pytorch
Issue: runtime error while using default arguments in add_graph() function
Labels: triaged,module: tensorboard,oncall: visualization

## 🐛 Bug

As per the documentation of `add_graph()` function from `torch.utils.tensorboard.writer.SummaryWriter` module, only `model` is the required parameter and rest of the parameters are given a default value.

However, when I try to call `add_graph()` using only `model` as input, I get a following runtime error 

```
Exception has occurred: TypeError
'NoneType' object is not iterable
  File "F:\projects\ai\autoencoder\pointnet-autoencoder-pytorch\train.py", line 62, in <module>
    writer.add_graph(autoencoder)

```
## To Reproduce

Steps to reproduce the behavior:

1. Create a model and call `add_graph()` function by passing only `model` and keep other parameters as default

## Expected behavior
`add_graph()` should not need input as a compulsory parameter as I would like to use this function to display the layers of my network graphically. 

## Environment

Collecting environment information...
PyTorch version: 1.5.0
Is debug build: No
CUDA used to build PyTorch: None

OS: Microsoft Windows 10 Pro
GCC version: Could not collect
CMake version: version 3.17.0

Python version: 3.6
Is CUDA available: No
CUDA runtime version: No CUDA
GPU models and configuration: No CUDA
Nvidia driver version: No CUDA
cuDNN version: No CUDA

Versions of relevant libraries:
[pip] numpy==1.14.2
[pip] torch==1.5.0
[pip] torchvision==0.6.0
[conda] _pytorch_select           1.1.0                       cpu
[conda] blas                      1.0                         mkl
[conda] cpuonly                   1.0                           0    pytorch
[conda] cudatoolkit               10.2.89              h74a9793_1
[conda] mkl                       2020.1                      216
[conda] numpy                     1.14.2           py36h5c71026_0
[conda] pytorch                   1.5.0               py3.6_cpu_0  [cpuonly]  pytorch
[conda] torchvision               0.6.0                  py36_cpu  [cpuonly]  pytorch
Repository: angular
Issue: TypeScript 3 Project References feature support
Labels: feature,area: compiler,feature: under consideration

### Bug Report or Feature Request (mark with an `x`)
```
- [ ] bug report -> please search issues before submitting
- [x] feature request
```

### Command (mark with an `x`)
```
- [ ] new
- [x] build
- [x] serve
- [x] test
- [ ] e2e
- [ ] generate
- [ ] add
- [ ] update
- [ ] lint
- [ ] xi18n
- [ ] run
- [ ] config
- [ ] help
- [ ] version
- [ ] doc
```

### Versions
Node: 10.13.0
NPM: 3.10.10
Angular CLI: 7.0.4
Windows 10

### Desired functionality
I would like to use TypeScript 3 Project References feature in Angular 7 project (created by Angular CLI).

### Mention any other details that might be useful
More about TypeScript 3 Project References: https://www.typescriptlang.org/docs/handbook/project-references.html
Repository: vscode
Issue: Search error: ENAMETOOLONG
Labels: bug,search,confirmed

When I press on Ctrl + P and enter the name of some JS or TS file, the files are not found. Only the last opened files are available. This is a recent problem, that appeared on the 1.45.1 version of Visual Studio code.
Repository: PowerToys
Issue: [Request] Shortcut to a context menu that doesn't have an existing shortcut.
Labels: Idea-New PowerToy

# Adding shortcut functionality to context menu items without an existing one

Sometimes there's software functions that get used a lot, but for some reason the developer has not assigned a default shortcut key combination to it. "File->Page setup" in notepad.exe for example.

It'd be nice to add a way for PowerToys' keyboard manager to look at what the context menus in a specific program contain, and be able to assign a shortcut for that. In the example above, it would look at notepad.exe and apply a user specified shortcut that would select file->page setup, if notepad is the active window (not unlike a macro or the MacOS keyboard shortcuts functionality).

Fantastic work so far, much appreciated!
Repository: godot
Issue: Problem with keeping aspect ratio in window when using macOS aspect-conserving resize
Labels: bug,platform:macos,topic:porting

**Godot version:**
3.2.1

**OS/device including version:**
mac OS X 10.11.16, OpenGL ES 3.0 Renderer: ATI Radeon HD 5870 OpenGL Engine


**Issue description:**
(Preface: I have the window resolutuion set to 256x192, display.window/stretch/mode is set to Viewport, and the Aspect is set to Keep)
![image](https://user-images.githubusercontent.com/26673668/82826097-74bd8e80-9e7a-11ea-831c-2a4dc2008117.png)

In Mac OS X, you can resize a window while keeping its aspect ratio by clicking and dragging while holding Shift. However, The game begins to generate black bars as though I am not keeping the ratio, despite me doing so. It can be seen both in enlarging the window, and reducing it.

![image](https://user-images.githubusercontent.com/26673668/82827207-8738c780-9e7c-11ea-82b3-7428e44e97b1.png)
(black bars made cyan for your convenience)

**Steps to reproduce:**
Set your window to any size, Set your mode to Viewport, aspect to Keep, and resize with ratio. Note that resizing the window through a script will keep the correct ratio.

**Minimal reproduction project:**
[Dawn.zip](https://github.com/godotengine/godot/files/4677937/Dawn.zip)
Repository: PowerToys
Issue: [Fancy Zones] Exclude app from snapping thru context menu
Labels: Idea-Enhancement,Product-FancyZones
Repository: flutter
Issue: Why is DropdownButtonFormField's onChanged required?
Labels: a: text input,framework,f: material design,c: proposal,P3,team-design,triaged-design

<!-- Thank you for using Flutter!

     If you are looking for support, please check out our documentation
     or consider asking a question on Stack Overflow:
      * https://flutter.dev/
      * https://api.flutter.dev/
      * https://stackoverflow.com/questions/tagged/flutter?sort=frequent

     If you have found a bug or if our documentation doesn't have an answer
     to what you're looking for, then fill our the template below. Please read
     our guide to filing a bug first: https://flutter.dev/docs/resources/bug-reports
-->

## Steps to Reproduce

Try to initialize a `DropdownButtonFormField` without specifying the `onChanged` parameter.

**Expected results:** <!-- what did you want to see? -->

For `onChanged` to not be required and the widget to still work, which is consistent with other FormField widgets, such as `TextFormField`.

**Actual results:** <!-- what did you see? -->

Currently the `onChanged` parameter is required and is seemingly used as a way to disable the widget if you set it to null. If you don't care about the onChanged event and just want to use the DropdownButtonFormField in a normal basic form, you still have to set onChanged to an empty function (e.g. `onChanged: (value) {}`) otherwise it won't update the FormState/stay enabled. This feels unintuitive to me since e.g. the `TextFormField` widget does not require you to specify `onChanged` unless you're interested in that event.

While I'm not that experienced with Flutter, it seems like it would make more sense to not use `onChanged` as a way of disabling a `DropdownButtonFormField` and instead let it purely be a way of letting the user do something when the field changes. I don't know if there are issues with that or if this odd current behavior is just a leftover from old logic? Seems easy enough to change it up (I could attempt to submit a PR for it).

**Proposed Changes:**
Add a `bool enabled` parameter to `DropdownButtonFormField` (consistent with TextFormField) and use that to decide whether to set the underlying `DropdownButton.onChanged` to control its enabled'ness.

In the future, it might make sense to add an `enabled` parameter to `DropdownButton` as well, as an explicit way of controlling whether it should be enabled or not.
Repository: PowerToys
Issue: [Run] Allow filter out app results
Labels: Idea-Enhancement,Product-PowerToys Run

# Summary of the new feature/enhancement

Sometimes it might be useful to filter out some apps/search result (maybe by regex for instance, or by context menu in the search results).

For example:

![image](https://user-images.githubusercontent.com/3112183/82835521-ee7e6800-9ecc-11ea-965e-3f3629280728.png)

For instance here I personally don't want to see "Character Map", "Weather Windows App" and "Private Character Editor" because I never used them and not going to do so, but I see them in search results. It might be the issue would be fixed in the search result will be sorted somehow (by usage and weight).
Repository: PowerToys
Issue: Keyboard manager breaks 3 and 4 finger touch pad taps with certain remaps
Labels: Issue-Bug,Product-Keyboard Shortcut Manager,Priority-1

<!--
**Important: When reporting BSODs or security issues, DO NOT attach memory dumps, logs, or traces to Github issues**.
Instead, send dumps/traces to secure@microsoft.com, referencing this GitHub issue.
-->

# Environment

```
Windows build number: 10.0.18363.836
PowerToys version: 0.18.1
PowerToy module for which you are reporting the bug (if applicable): Keyboard manager
```

# Steps to reproduce
1. Configure an action for 3/4 finger tap in Windows Settings -> Devices -> Touchpad
2. Turn on Keyboard manager in PowerToys settings
3. Remap Alt with Control
4. Remap Control with Alt

# Expected behavior
For 3 and 4 finger tap gestures configured in settings to work
For the Control and Alt key to be swapped 

# Actual behavior
3 and 4 finger taps do nothing
Control and Alt key do still swap as they should
<!-- What's actually happening? -->

# Screenshots

<!-- If applicable, add screenshots to help explain your problem. -->
Repository: node
Issue: doc: some methods inherited from Uint8Array are documented but not all
Labels: buffer,doc

# 📗 API Reference Docs Problem

<!------------------------------------------------------------------------------
Thank you for wanting to make nodejs.org better!

This template is for issues with the Node.js API reference docs.

For more general support, please open an issue in
our help repo at “https://github.com/nodejs/help”.

For the issue title, enter a one-line summary after “doc: ”.
The “✍️” signifies a request for input. If unsure, do the best you can.

If you found a problem with nodejs.org beyond the API reference docs, please
open an issue in our website repo at “https://github.com/nodejs/nodejs.org”.
------------------------------------------------------------------------------->

<!--
Version: output of “node -v”
Platform: output of “uname -a” (UNIX), or version and 32 or 64-bit (Windows)
Subsystem: if known, please specify affected core module name
-->

- **Version**: master
- **Subsystem**: buffer

## Location

Affected URL(s):
- https://nodejs.org/api/buffer.html

## Problem description

<!-- If applicable, include any screenshots that may help solve the problem. -->

Some methods inherited from `Uint8Array` are not documented, e.g. `map`, `reduce`, `set`. This makes sense because it's stated that the `Buffer` class is a subclass of the `Uint8Array` class, but some _are_ documented, e.g. `entries`, `keys`, `values`. This might be confusing.

---

<!-- Use “[x]” to check the box below if interested in contributing. -->

- [x] I would like to work on this issue and submit a pull request.
Repository: PowerToys
Issue: [FancyZones] Allow window to be "locked" in place
Labels: Idea-Enhancement,Product-FancyZones

# Summary of the new feature/enhancement

I am always accidentally moving or resizing my zoned windows, especially edge when i go to click on a tab.  It would be nice if we could "lock" these windows into their zone to protect against accidental nudging.  Either have the window snap back to it's original position, ~allow it to be "maximized" into the zone so it won't accidentally move, or just prevent movement.~  There could be a hotkey to override this behavior to intentionally move a "locked" window.  

This should clearly be an optional setting, as i can see now it might annoy some people, or confuse people that are new to the product.
Repository: deno
Issue: Deno lacks a cookie jar for `fetch`
Labels: web,suggestion,ext/fetch

Deno should store cookies on a per-run basis (and optionally have methods in the Deno namespace for export/import of cookies) so that it's possible to make a series of requests that depend on cookies. 

Right now, a flow like the following would be impossible:

1. No cookies sent; response sets cookie 1.
2. Cookie 1 sent; response uses cookie 1 value somewhere in the body

Yes, I'm aware of `std/http/cookie`. No, it's not what I need - this is not a server. It's a client.
Repository: rust
Issue: mod-with-a-body silently ignores any "mod.rs" (could have a better diagnostic?)
Labels: C-enhancement,A-diagnostics,T-compiler

I tripped over this learning how the module system works and splitting things into multiple files.

If you write 

```rust
// lib.rs
pub mod foo;
```

it looks for `foo/mod.rs`, and it all works fine. But let's say I want to add a submodule inside `foo`. So I changed `lib.rs` to look like this:

```rust
// lib.rs
pub mod foo {
    pub mod sub;
}
```

Now `mod foo` has a body, so it does not look for `foo/mod.rs`. But I didn't know this rule, and it doesn't give me any indication that it skipped that file. Instead, I just get unresolved import errors as if all the stuff inside the `foo` module has magically disappeared.

It'd be nice if it said something along the lines of `"warning: ignoring foo/mod.rs as a body was found in lib.rs"` or so.

### Meta

`rustc --version --verbose`:
```
rustc 1.45.0-nightly (2d03399f5 2020-04-27)
binary: rustc
commit-hash: 2d03399f53d28a8be645625376c0c9fbe601a01d
commit-date: 2020-04-27
host: x86_64-apple-darwin
release: 1.45.0-nightly
LLVM version: 9.0
```