sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: angular
Issue: Improve DX for identifying missing or unused module imports
Labels: feature,area: core,area: language-service,core: directive matching,feature: under consideration

# 🚀 feature request

### Relevant Package

This feature request is for @angular/core or @angular/compiler (?)

### Description

Angular will currently detect (and complain) if a directive with an input binding exists, but the directive is not known (due to its defining module not being imported):

```
<app-child [myAwesomeDirective]="42"></app-child>
```

However, this doesn't work for directives without an input binding, i.e.

```
<app-child myAwesomeDirective></app-child>
```

The reason for this is – I believe – that `myAwesomeDirective` is treated as an HTML attribute (which makes sense), and HTML attributes are, well, legal HTML. And custom attributes are specifically frequently used as content projection selectors.

However, this causes a couple of issues in the developer experience, specifically

1. No error being shown if you forget to import the module.
2. Making it unsafe to try and identify unused module imports through trial & error of removing them (and there being a lack of alternatives to safely do so).

### Describe the solution you'd like

I don't have a specific solution in mind which I think can be considered good enough. Initially I thought about a new strictness setting which fails on unknown HTML attributes, but especially due to the content projection case this would be problematic and a setting I'd only activate for this specific purpose (which feels awkward); in terms of HTML, there's nothing "illegal" about unknown attributes.

I will point out, however, that IDEs such as IntelliJ can and do warn about unknown HTML attributes, even taking content projection into consideration for this. This is somewhat suitable for case (1), though only for code as you write it, not when e.g. moving a component to a different module, and it doesn't cover (2) which is actually my main concern as there's currently no good way of "housekeeping" module imports in a safe, reliable manner. To clarify, this isn't about tree-shaking, unused modules can of course be tree-shaken, but rather about general maintenance and maybe ultimately even allowing to uninstall unused dependencies.

I'm not sure what, if anything, can be reasonably done here, but would like to at least open this for visibility.

---

To give an example, UI libraries such as Angular Material or ng-zorro-antd require you to import components individually. So you end up importing your buttons, checkboxes, tabs and what have you. But the list only ever grows and can be tough to reduce it down to what is actually needed later on.
Repository: TypeScript
Issue: Destructuring or bracket notation on `never` shouldn't be allowed
Labels: Suggestion,Awaiting More Feedback

# Bug Report

You can destructure or use bracket notation on `never` type, but you can't access props using the dot notation. It should disallow all forms of property access.

### 🔎 Search Terms

never destructuring destructure bracket dot notation

### 🕗 Version & Regression Information

- This is the behavior in every version I tried, and I reviewed the FAQ :heavy_check_mark:
  - [3.9.7](https://www.typescriptlang.org/play?ts=3.9.7#code/MYewdgzgLgBA3jADgJxImBfGBeGAKOLAQwhjAFMA3c5ASgG4BYAKFElhTQCYd9CYSZKjVoBtAESdE4gLr0gA)
  - [4.1.5](https://www.typescriptlang.org/play?#code/MYewdgzgLgBA3jADgJxImBfGBeGAKOLAQwhjAFMA3c5ASgG4BYAKFElhTQCYd9CYSZKjVoBtAESdE4gLr0gA)
  - [Nightly](http://www.typescriptlang.org/play/?ts=Nightly#code/MYewdgzgLgBA3jADgJxImBfGBeGAKOLAQwhjAFMA3c5ASgG4BYAKFElhTQCYd9CYSZKjVoBtAESdE4gLr0gA)

### ⏯ Playground Link

[Playground link](https://www.typescriptlang.org/play?ts=4.1.5#code/MYewdgzgLgBA3jADgJxImBfGBeGAKOLAQwhjAFMA3c5ASgG4BYAKFElhTQCYd9CYSZKjVoBtAESdE4gLr0gA)

### 🙁 Actual behavior

```ts
const { prop } = ({} as never); // does not error
const prop2 = ({} as never)["prop"]; // does not error
```


### 🙂 Expected behavior

TS should not allow this, same as you can't access props using the dot notation:

```ts
const prop = ({} as never).prop; // error
```
Repository: go
Issue: cmd/compile: unnecessary copy in regalloc
Labels: Performance,NeedsInvestigation,compiler/runtime

After CLs 297049 and 297050,  generate code for shrVU_g in math/big.

The result includes these two instructions:

v121    00026 (+181) LEAQ 1(R10), R8
v107    00027 (181) MOVQ R8, CX

After this, R8 is dead. So this could have just been one instruction, `LEAQ 1(R10), CX`. Here's the relevant block after regalloc:

<img width="422" alt="Screen Shot 2021-02-27 at 11 36 04 AM" src="https://user-images.githubusercontent.com/67496/109398186-079ac600-78f0-11eb-87ee-3130cdefdc22.png">

This is the sort of thing a peephole pass could help with (https://github.com/golang/go/issues/15300), but maybe now that Values have Uses counts there's a way to detect and improve this in regalloc directly.

cc @randall77 @cherrymui
Repository: go
Issue: cmd/compile: regalloc fails to reserve key register (CX) for future code
Labels: Performance,NeedsInvestigation,compiler/runtime

After CLs 297049 and 297050, generate code for shrVU_g in math/big.

The tight inner loop compiles to:

```
v94     00020 (+182) MOVQ -8(DX)(CX*8), R8
v106    00021 (182) MOVQ (DX)(CX*8), R9
v133    00022 (181) MOVQ CX, R10
v117    00023 (182) MOVQ SI, CX
v109    00024 (182) SHRQ CX, R9, R8
v119    00025 (182) MOVQ R8, -8(DI)(R10*8)
v121    00026 (+181) LEAQ 1(R10), R8
v107    00027 (181) MOVQ R8, CX
```

This contains unnecessary copies. One is #44670.

The others are `CX` contention. Regalloc decided to put `i` in `CX`. Unfortunately, `CX` is the required register for the shift amount input for the `SHRDQ` instruction. So we shuffle  `i` in and out of `CX` on every iteration.

I thought regalloc had some amount of lookahead to avoid using highly restricted registers in upcoming code, to avoid this situation. Either I was wrong, or it isn't working as desired here.

I believe that fixing this issue would make the generated code as fast (or nearly so) as the hand-written assembly, allowing us to delete the assembly.

cc @randall77 @cherrymui
Repository: godot
Issue: AudioStreamGeneratorPlayback delay
Labels: documentation,topic:audio

**Godot version:**
3.2.4-rc4

**OS/device including version:**
Windows 10

**Issue description:**
I'm currently developing a new version of my godot-voip plugin which uses the new AudioEffectCapture for real time voice input.  (see: https://github.com/casbrugman/godot-voip/pull/7) To take advantage of this I switched from using a regular AudioStreamPlayer to using a AudioStreamGeneratorPlayback to play the voice input in real time. However this introduced a significant amount of latency even when used locally. This does not seem like expected behavior and I'm not sure what causes this or what can be done about this.

**Steps to reproduce:**
Push audio frames into an AudioStreamGeneratorPlayback.

**Minimal reproduction project:**
[godot-voip-e119e3bcadf98e37f0de2e3e3d1bfa4bba59dd7e.zip](https://github.com/godotengine/godot/files/6055515/godot-voip-e119e3bcadf98e37f0de2e3e3d1bfa4bba59dd7e.zip)
Repository: flutter
Issue: [Web] Inconsistent theming on Samsung Internet
Labels: framework,platform-web,has reproducible steps,P2,found in release: 2.10,found in release: 2.13,team-web,triaged-web


## Steps to Reproduce

visit: [Flutter Gallery](https://gallery.flutter.dev/) or another flutter web app.
Compare Chrome/Edge to Samsung Internet with respective dark modes enabled.

**Expected results:** 
Expected website to be rendered in the dark theme across all platforms.

**Actual results:** 
Samsung Internet overrides theming with inconsistent results.
Most colours are darker than they should be, but don't seem to follow a set pattern.
For example, I have a list of cards with text. The card theme colour is set to blueGrey and the text is white.
Sometimes the card is blueGrey(ish), sometimes it is black. Sometimes the text is white, sometimes it is black. 
This can all be within the same list as you can see on the following screenshots.

when you scroll through the list the items can also randomly change colour.


<Details>

![Screenshots](https://user-images.githubusercontent.com/70274454/109402037-6856ec80-794a-11eb-9676-0a106cfd8afb.jpg)

</Details>
Repository: godot
Issue: Inconsistent behaviour of ?-operator in shader language on Mac
Labels: bug,platform:macos,topic:thirdparty,topic:shaders


**Godot version:**
3.2.3 Stable Official


**OS/device including version:**
MacBook Pro – MacOS Big Sur v. 11.2.1
Radeon Pro 560 4 GB
Intel HD Graphics 630 1536 MB

Windows 10

**Issue description:**
There are inconsistencies in how Godot's shader language handles the ?-operator between Mac and Windows, and in different contexts on Mac.

**Steps to reproduce:**
```
shader_type canvas_item;

uniform bool text_check;
uniform bool uv_check;

void fragment()
{
	vec4 text = texture(text_check ? SCREEN_TEXTURE : TEXTURE, uv_check ? UV : SCREEN_UV);
	
	COLOR = text;
}
```

Consider this code. On Mac, checking and unchecking `uv_check` and `text_check` will flip between `UV` and `SCREEN_UV` as you would expect, but not between `SCREEN_TEXTURE` and `TEXTURE`. It will only default to the last option, `TEXTURE` in this case.

Both are allowed, there is no error message, and `text_check` is working on Windows, which makes me suspect this is a bug on Mac and not intentional. 

**Minimal reproduction project:**
<!-- A small Godot project which reproduces the issue. Drag and drop a zip archive to upload it. -->
Repository: godot
Issue: Panel control with Stylebox set to Draw Center has 1px error
Labels: bug,topic:gui

<!-- 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. -->
Godot 3.2.3 stable.

**OS/device including version:**
<!-- Specify GPU model, drivers, and the backend (GLES2, GLES3, Vulkan) if graphics-related. -->
Both GLES3 and GLES2. Windows 10. Nividia 930M.

**Issue description:**

Panel stylebox does not always respect its own rect size, and children it will bleed by 1-2 pixels. This happens when zooming in/out the editor, or when running the game with the stretch mode set to anything other than None.

I expect the Panel stylebox to stick to its specified size regardless of screen resolution or zoom.

In this below picture you can see the edges of the Panel that is supposed to be completely hidden by the ColorRect in front of it.

Note that toggling "snap_controls_to_pixels" in project settings also did not help.

<!-- What happened, and what was expected. -->
![image](https://user-images.githubusercontent.com/43449832/109402721-27ba9b80-7969-11eb-8b3d-1299a1dc1c25.png)
![image](https://user-images.githubusercontent.com/43449832/109402723-33a65d80-7969-11eb-80b6-a4ffd6dec861.png)


**Steps to reproduce:**
- Create Panel node 
- Add Stylebox and set to Draw Center
- Add child ColorRect set to Full Rect layout (to help visualize the error)
- Scroll in/out in the editor (or launch the game and resize the screen)

**Minimal reproduction project:**
<!-- A small Godot project which reproduces the issue. Drag and drop a zip archive to upload it. -->
[panel_style_flicker.zip](https://github.com/godotengine/godot/files/6055815/panel_style_flicker.zip)
Repository: godot
Issue: No shadowing warning when argument is used in for loop
Labels: bug,topic:gdscript

<!-- 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.4 rc3

**Issue description:**
<!-- What happened, and what was expected. -->
Title.
```
func test(arg):
	for arg in 4:
		pass
```
Repository: godot
Issue: Runaway memory leak setting child array from parent _Ready()
Labels: bug,topic:dotnet

<!-- 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.mono.official

**OS/device including version:**
Windows 10 x64 (20H2)

**Issue description:**
Attempting to set the `Points` array of a `Line2D` from a parent node in a CSharpScript `_Ready()` function causes a memory leak which will eventually consume all available memory.  Attempting to view the memory monitor from Godot (if the process is attached to the editor instance instead of running a new process externally such as with a vscode launch config) can cause the leak to spread to the editor process.  There are some issues setting `Points` in gdscript too, but does not cause a runaway leak such as the following:

```gdscript
    public override void _Ready()
    {
        var osc = GetNode<Line2D>("Osc");
        osc.Points = new Vector2[4096];
    }
```

**Steps to reproduce:**
Run the attached project.    **WARNING:**  Do not run the project for more than a few moments as the process doesn't seem to automatically close itself when memory has been exhausted and your PC may become unresponsive.

**Minimal reproduction project:**
<!-- A small Godot project which reproduces the issue. Drag and drop a zip archive to upload it. -->
[PhaseEngine.zip](https://github.com/godotengine/godot/files/6056237/PhaseEngine.zip)
Repository: rust
Issue: Confusing mismatched type error message with `generic_const_exprs`
Labels: A-diagnostics,T-compiler,D-papercut,F-generic_const_exprs

I'd be happy to try to fix this, but some pointers on where to start would be greatly appreciated.

Given the following code - [playground](https://play.rust-lang.org/?version=nightly&mode=debug&edition=2018&gist=962c845e9dbe023df736f78ef7dd6e87):

```rust
#![allow(incomplete_features)]
#![feature(const_generics)]
#![feature(const_evaluatable_checked)]

use std::ops::Add;

struct ConstWrapper<const N: usize>;
impl<const N1: usize, const N2: usize> Add<ConstWrapper<N2>> for ConstWrapper<N1>
where ConstWrapper<{N1 + N2}>: Sized
{
   type Output = ConstWrapper<{N1 + N2}>;
   fn add(self, _other: ConstWrapper<N2>) -> Self::Output {
       ConstWrapper
   }
}

struct WrapConstWrapper<T>(T);
impl<T1: Add<T2>, T2> Add<WrapConstWrapper<T2>> for WrapConstWrapper<T1> {
    type Output = WrapConstWrapper<<T1 as Add<T2>>::Output>;
    fn add(self, other: WrapConstWrapper<T2>) -> Self::Output {
        WrapConstWrapper ( self.0 + other.0 )
    }
}

fn get_0() -> WrapConstWrapper<ConstWrapper<0>> {
    WrapConstWrapper(ConstWrapper)
}

fn main() {
    let x: WrapConstWrapper<ConstWrapper<1>> = get_0() + get_0();
    let y = get_0() + get_0();
    let z: WrapConstWrapper<ConstWrapper<1>>;
    z = y;
}
```

The current output is:

```
error[E0308]: mismatched types
  --> src/main.rs:30:48
   |
30 |     let x: WrapConstWrapper<ConstWrapper<1>> = get_0() + get_0();
   |                                                ^^^^^^^^^^^^^^^^^ expected `1_usize`, found `0_usize`
   |
   = note: expected type `1_usize`
              found type `0_usize`

error[E0308]: mismatched types
  --> src/main.rs:33:9
   |
33 |     z = y;
   |         ^ expected `1_usize`, found `0_usize`
   |
   = note: expected struct `WrapConstWrapper<ConstWrapper<1_usize>>`
              found struct `WrapConstWrapper<ConstWrapper<0_usize>>`
```
Ideally, the error messages would be identical. Removing the `{N1 + N2}` calculation allows the compiler to provide the same error message for both bindings (as seen [here](https://play.rust-lang.org/?version=nightly&mode=debug&edition=2018&gist=ff5b114f8623ec10e1940ee347c6676d)). It appears that the compiler is stopping at the mismatched constant instead of evaluating the entire type of `get_0() + get_0()`.
Repository: ant-design
Issue: All checkboxes are re-rendered in each render in a table with rowSelection enabled
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.

### Reproduction link
[![Edit on CodeSandbox](https://codesandbox.io/static/img/play-codesandbox.svg)](https://codesandbox.io/s/antd-playground-rowselection-table-9cnj9)

### Steps to reproduce
- open the [codesandbox demo](https://codesandbox.io/s/antd-playground-rowselection-table-9cnj9) in a new window
- open the react dev tools profiler tab, check **Record why each component rendered while profiling.**
- start the react dev tools profiling
- check one record in the demo table
- stop the react dev tools profiling
- in the flamegraph, one can see every single checkbox is re-rendered with reasons saying: **"Props changed: (onClick, onChange)"**
![](https://images2.imgbox.com/54/2b/qB4k3iBR_o.png)

### What is expected?
Only the relative checkbox should be re-rendered.

### What is actually happening?
All checkboxes are re-rendered.

| Environment | Info |
|---|---|
| antd | 4.12.3 |
| React | 17.0.1 |
| System | Windows 10 Pro 20H2 19042.804 |
| Browser | Microsoft Edge 88.0.705.74 |

---
There will be a noticeable UI lagging when there are hundreds of records in a table. onClick and onChange shouldn't be updated in each render.


<!-- generated by ant-design-issue-helper. DO NOT REMOVE -->
Repository: go
Issue: x/playground: web app runtime error with file/dir name conflicts in the txtar
Labels: NeedsFix

### What did you do?

Run the following in the Go Playground: https://play.golang.org/p/92soX8Gyrsn

```go
package main

func main() {}
-- a --
-- a/b --
```

### What did you expect to see?

It should tell there's a file/dir name conflict in the txtar.

### What did you see instead?

```
Error communicating with remote server.
Program exited.
```

### Addtional info

The playground web app emits either of the following runtime errors when there's a file/dir name conflict:

```
cmdFunc error: mkdir /tmp/sandbox253661173/a: not a directory
```
```
cmdFunc error: error creating temp file "/tmp/sandbox446449006/a": open /tmp/sandbox446449006/a: is a directory
```
Repository: flutter
Issue: Customising overflow position for Text Widget
Labels: c: new feature,framework,engine,a: typography,c: proposal,customer: money (g3),P1,team-engine,triaged-engine

Currently, [Text](https://github.com/flutter/flutter/blob/master/packages/flutter/lib/src/widgets/text.dart#L471) widget supports only limited options for painting overflowed text.

Can we customize the overflow options to support custom truncation positions eg. before `@` for emails? For reference, iOS SDK also [supports](https://developer.apple.com/documentation/quartzcore/catextlayer/truncation_modes) three different types of modes.

Other open issues related to this -
- https://github.com/flutter/flutter/issues/45336
- https://github.com/flutter/flutter/issues/26748

Internal bug - b/180975303
Repository: vscode
Issue: [remote cli] support opening `file` URIs
Labels: feature-request,remote,workbench-cli

<!-- ⚠️⚠️ Do Not Delete This! bug_report_template ⚠️⚠️ -->
<!-- Please read our Rules of Conduct: https://opensource.microsoft.com/codeofconduct/ -->
<!-- 🕮 Read our guide about submitting issues: https://github.com/microsoft/vscode/wiki/Submitting-Bugs-and-Suggestions -->
<!-- 🔎 Search existing issues to avoid creating duplicates. -->
<!-- 🧪 Test using the latest Insiders build to see if your issue has already been fixed: https://code.visualstudio.com/insiders/ -->
<!-- 💡 Instead of creating your report here, use 'Report Issue' from the 'Help' menu in VS Code to pre-fill useful information. -->
Version: 1.53.2 (system setup)
Commit: 622cb03f7e070a9670c94bae1a45d78d7181fbd4
Date: 2021-02-11T11:48:04.245Z
Electron: 11.2.1
Chrome: 87.0.4280.141
Node.js: 12.18.3
V8: 8.7.220.31-electron.0
OS: Windows_NT x64 10.0.19041

Steps to Reproduce:

1. Connect to a WSL remote
2. Switch to the terminal
3. Run `$BROWSER 'file:///tmp'`

Result: 
![a pop up asking to install an application to handle specific kind of handler](https://user-images.githubusercontent.com/190463/109419025-33d34700-79c3-11eb-8c3f-9106a2c39ce3.png)

Expected: 
Browser launching on Windows side with `file://///wsl$/Debian/tmp`.

Curiously enough, running `$BROWSER 'file://///wsl$/Debian/tmp'` directly results in the `browser.sh` timing out with:
```
Unable to connect to VS Code server.
Error in request
```

Opening `file://///wsl$/Debian/tmp` directly in the host's browser works just fine.

Context: `mechanicalsoup` has a debug method that users python's `browser` module to open a browser with debug copy of downloaded page. Due to the above, can't use it easily right now :(

<!-- 🔧 Launch with `code --disable-extensions` to check. -->
Does this issue occur when all extensions are disabled?: Yes

<!-- 🪓 If you answered No above, use 'Help: Start Extension Bisect' from Command Palette to try to identify the cause. -->
<!-- 📣 Issues caused by an extension need to be reported direct to the extension publisher. The 'Help > Report Issue' dialog can assist with this. -->