sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: TypeScript
Issue: Add an option to ignore type checking for certain files
Labels: Suggestion,In Discussion

# Suggestion

## 🔍 Search Terms

Ignore files directories type checking

## ✅ Viability Checklist

My suggestion meets these guidelines:

* [X] This wouldn't be a breaking change in existing TypeScript/JavaScript code
* [X] This wouldn't change the runtime behavior of existing JavaScript code
* [X] This could be implemented without emitting different JS based on the types of the expressions
* [X] This isn't a runtime feature (e.g. library functionality, non-ECMAScript syntax with JavaScript output, new syntax sugar for JS, etc.)
* [X] This feature would agree with the rest of [TypeScript's Design Goals](https://github.com/Microsoft/TypeScript/wiki/TypeScript-Design-Goals).


## ⭐ Suggestion

Add an option like 
```
nocheck: ["external-files/**"]
```
for tsconfig.json that effectively works like adding `// @ts-nocheck` to each and every matching file. 

## 📃 Motivating Example

"Do you have a problem with types in files by external authors and have no way to solve it? Have you begged and asked for a fix only to be ignored? Now you can add "nocheck" to tsconfig.json and ignore the problems you cannot solve."

## 💻 Use Cases

The `skipLibCheck` option in `tsconfig.json` allows us to deal with problems in types in dependencies by not performing checks on those files. In our case (Vaadin) we also get dependencies from other locations (Java jar files) and they will not end up in `node_modules` because other tools like Vite assume that dependencies inside `node_modules` will not change and thus will not hot deploy changes from there. So the files get put in another folder, let's say `external-files/**`.

We however have the same problem that `skipLibCheck` to my understanding tries to solve: Sometimes the TS author either just writes incorrect TS that still works or she is using less strict options in `tsconfig.json` (e.g. other author uses `noUnusedLocals": false` and project uses `noUnusedLocals": true`). This leads to problems when including the TS files in another project and compiling that: the project won't compile even though it would work perfectly well.
Repository: angular
Issue: ReactiveForms: no key check on strictly typed FormGroups when all keys are optional
Labels: area: forms

### Which @angular/* package(s) are the source of the bug?

forms

### Is this a regression?

No

### Description

Methods like setControl, addControl and removeControl on FormGroup do not check, if the given name parameter is a valid key in the FormGroup's generic type, when the generic type contains only optional keys.


Bug when all keys in generic type optional:
```
let form!: FormGroup<{ a?: FormControl<string | null> }>;
form.setControl("b", new FormControl("x")); // <-- unexpectedly no error
```

Normal usage/expected behaviour:

```
let form!: FormGroup<{ a: FormControl<string | null> }>;
form.setControl("b", new FormControl("x")); // <-- error as expected
// error TS2769: No overload matches this call.
//   Overload 1 of 2, '(name: "a", control: FormControl<string | null>, options?: { emitEvent?: boolean | undefined; } | undefined): void', gave the following error.
//     Argument of type '"b"' is not assignable to parameter of type '"a"'.
//   Overload 2 of 2, '(this: FormGroup<{ [key: string]: AbstractControl<any, any>; }>, name: string, control: AbstractControl<any, any>, options?: { emitEvent?: boolean | undefined; } | undefined): void', gave the following error.
//     The 'this' context of type 'FormGroup<{ a: FormControl<string | null>; }>' is not assignable to method's 'this' of type 'FormGroup<{ [key: string]: AbstractControl<any, any>; }>'.
//       Property 'a' is missing in type '{ [key: string]: AbstractControl<any, any>; }' but required in type '{ a: FormControl<string | null>; }'.
```


It seems that the method signatures intended for untyped FormGroups takes over

```
removeControl(this: FormGroup<{
        [key: string]: AbstractControl<any>;
    }>, name: string, options?: {
        emitEvent?: boolean;
    }): void;
```

as `FormGroup<{ a?: any }>` is assignable to `FormGroup<{ [key: string]: AbstractControl<any>; }` while `FormGroup<{ a: any }>` is not

### Please provide a link to a minimal reproduction of the bug

https://stackblitz.com/edit/angular-ivy-xkdc6n?file=src%2Fapp%2Fapp.component.ts

### Please provide the exception or error you saw

_No response_

### Please provide the environment you discovered this bug in (run `ng version`)

```true
Angular CLI: 14.1.3
Node: 16.17.1
Package Manager: npm 8.15.0
OS: win32 x64

Angular: 14.1.3
... animations, cdk, cli, common, compiler, compiler-cli, core
... forms, platform-browser, platform-browser-dynamic, router

Package                         Version
---------------------------------------------------------
@angular-devkit/architect       0.1401.3
@angular-devkit/build-angular   14.1.3
@angular-devkit/core            14.1.3
@angular-devkit/schematics      14.1.3
@schematics/angular             14.1.3
rxjs                            7.5.7
typescript                      4.7.4
```


### Anything else?

_No response_
Repository: godot
Issue: Exporting android with mangohud enable, without using the enviroment variable, godot fails to sign the apk
Labels: bug,platform:android,topic:editor,topic:thirdparty,topic:export

### Godot version

v4.0.beta.custom_build [28a24639c]

### System information

EndeavourOS Linux

### Issue description

If mangohud its enable with the command godot fails to sign export apk with:

`WARNING: Firma del Código: All 'apksigner' tools located in Android SDK 'build-tools' directory failed to execute. Please check that you have the correct version installed for your target sdk version. The resulting APK is unsigned.`

If mangohud is loaded with the environment variable (MANGOHUD=1) works just fine.

### Steps to reproduce

Just start godot on a command line with 

`mangohud godot`

and export a project to android

### Minimal reproduction project

N/A
Repository: godot
Issue: Missing autocompletion for nested types
Labels: bug,topic:gdscript,topic:editor

### Godot version

v4.0.beta13.official [caacade56]

### System information

Windows 11

### Issue description

No autocompletion suggestions are provied when giving type hints for a nested type.

### Steps to reproduce

Consider the following:

```
# foo.gd
enum NestedEnum {
	CONSTANT_ONE,
	CONSTANT_TWO
}

# bar.gd
# There is no "Foo.NestedEnum" in the autocompletion when writing the type hint.
var e: Foo.NestedEnum
```

### Minimal reproduction project

[bug_no_autocompletion_when_type_hinting_with_nested_type.zip](https://github.com/godotengine/godot/files/10466809/bug_no_autocompletion_when_type_hinting_with_nested_type.zip)
Repository: rust
Issue: println panic suppressed by test harness stdio capture
Labels: A-libtest,C-bug,T-libs

<!--
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.
-->

This code prints `something` then panics, which seems fine:

https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=1f799e1599b2e8b7ecac0963864b8020


```rust
use std::fmt;

struct FailingDisplay;

impl fmt::Display for FailingDisplay {
    fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
        writeln!(f, "something")?;
        Err(fmt::Error)
    }
}

fn main() {
    eprintln!("{}", FailingDisplay)
}
```
```
     Running `target/debug/playground`
something
thread 'main' panicked at 'failed printing to stderr: formatter error', library/std/src/io/stdio.rs:1009:9
```

Let’s add a test for this behavior. (In reality, this is a non-regression test that will stop panicking when I fix a bug that make the `Display` impl return an error.)

https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=2382727df2a6289b4108cdb959cd14af

```rust
#[test]
#[should_panic]
fn test() {
    eprintln!("{}", FailingDisplay)
}
```

I expected to see this happen: `eprintln!` panics in the test, same as in `main`

Instead, this happened: the test prints `something` but does *not* panic unless it is run with `--nocapture`. I did not expect output capturing to affect whether something panics.

```
running 1 test
test test - should panic ... FAILED

failures:

---- test stdout ----
something
note: test did not panic as expected

failures:
    test

test result: FAILED. 0 passed; 1 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s
```

### Meta
<!--
If you're using the stable version of the compiler, you should also check if the
bug also exists in the beta or nightly versions.
-->

Identical results with three Rust versions:

* On playground: Build using the Stable version: 1.66.1
* On playground: Build using the Nightly version: 1.68.0-nightly (2023-01-19 4c83bd03a9d94af35c97)
* In my larger project:

`rustc --version --verbose`:
```
rustc 1.65.0 (897e37553 2022-11-02)
binary: rustc
commit-hash: 897e37553bba8b42751c67658967889d11ecd120
commit-date: 2022-11-02
host: aarch64-apple-darwin
release: 1.65.0
LLVM version: 15.0.
```
Repository: rust
Issue: Incorrect docs generated for `derive_const` traits
Labels: T-rustdoc,F-const_trait_impl

This is currently in beta; not yet in stable.

The beta docs ([here](https://doc.rust-lang.org/beta/std/cmp/enum.Ordering.html#impl-PartialEq%3COrdering%3E-for-Ordering)) show that the `PartialEq` and `PartialOrd` implementations of `std::cmp::Ordering` are `const`.

![derive_const](https://user-images.githubusercontent.com/5100376/213727975-15047314-f882-45ac-99d4-108974f1110d.png)

Same for [`TypeId`](https://doc.rust-lang.org/nightly/std/any/struct.TypeId.html#impl-PartialEq%3CTypeId%3E-for-TypeId) (only in nightly for now).

Both use `derive_const` to generate the trait implementations.
Const traits do not work outside nigthly, and only with feature `const_trait_impl` enabled, so they should not be marked as such in the documentation.

Trying to use these methods in a const context gives an error, as intended:
https://play.rust-lang.org/?version=beta&mode=debug&edition=2021&gist=bba4e8edb1baa3743739b3cb207e6892
Repository: pytorch
Issue: Torchscript troubles with complex values. RuntimeError: isInt() INTERNAL ASSERT FAILED
Labels: oncall: jit,triaged,module: complex

### 🐛 Describe the bug

Torchscript errors out when creating imaginary coefficients. This simple example runs fine in pytorch without torchscript. I'd expect to get the same result with torch and torchscript. 

```
import torch

class SimpleEx(torch.nn.Module):
    def __init__(self):
        super(SimpleEx, self).__init__()
        self.k = 1.23

    def forward(self):
        a = torch.randn(3)
        b = torch.randn(11,11)
        return 1j*self.k/2*(1-a[1])/a[0]*b

if __name__ == '__main__':

    se = torch.jit.script(SimpleEx())
    se_out = se()
    print(se_out)
```

The following error is produced when running as a module

Traceback (most recent call last):
  File "/usr/lib/python3.8/runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.8/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/home/user/SimpleEx.py", line 17, in <module>
    se_out = se()
  File "/home/user/my_venv/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1194, in _call_impl
    return forward_call(*input, **kwargs)
RuntimeError: The following operation failed in the TorchScript interpreter.
Traceback of TorchScript (most recent call last):
  File "/home/user/SimpleEx.py", line 12, in forward
        a = torch.randn(3)
        b = torch.randn(11,11)
        return 1j*self.k/2*(1-a[1])/a[0]*b
               ~~~~~~~~~~~ <--- HERE
RuntimeError: isInt() INTERNAL ASSERT FAILED at "../aten/src/ATen/core/ivalue.h":602, please report a bug to PyTorch.



### Versions

Collecting environment information...
PyTorch version: 1.13.1+cpu
Is debug build: False
CUDA used to build PyTorch: Could not collect
ROCM used to build PyTorch: N/A

OS: Ubuntu 20.04.5 LTS (x86_64)
GCC version: (Ubuntu 9.4.0-1ubuntu1~20.04.1) 9.4.0
Clang version: Could not collect
CMake version: version 3.16.3
Libc version: glibc-2.31

Python version: 3.8.10 (default, Nov 14 2022, 12:59:47)  [GCC 9.4.0] (64-bit runtime)
Python platform: Linux-5.4.0-136-generic-x86_64-with-glibc2.29
Is CUDA available: False
CUDA runtime version: Could not collect
CUDA_MODULE_LOADING set to: N/A
GPU models and configuration: GPU 0: Quadro P1000
Nvidia driver version: 495.29.05
cuDNN version: Could not collect
HIP runtime version: N/A
MIOpen runtime version: N/A
Is XNNPACK available: True

Versions of relevant libraries:
[pip3] numpy==1.23.4
[pip3] torch==1.13.1+cpu
[pip3] torchvision==0.14.1+cpu
[conda] Could not collect

cc @EikanWang @jgong5 @wenzhe-nrv @sanchitintel @ezyang @anjali411 @dylanbespalko @mruberry @Lezcano @nikitaved
Repository: material-ui
Issue: [Slider] component cannot be dragged if parent element uses `e.preventDefault()`
Labels: bug 🐛,component: slider

### Duplicates

- [X] I have searched the existing issues

### Latest version

- [X] I have tested the latest version

### Steps to reproduce 🕹

Link to live example: [https://codesandbox.io/s/hardcore-silence-ywxfbo?file=/src/App.js](https://codesandbox.io/s/hardcore-silence-ywxfbo?file=/src/App.js)

Steps:

1. Stop propagation of "mousemove" on the parent of the slider i.e.`onMouseMove={(e) => e.stopPropagation()}`
2. Try to drag the thumb  of the slider


### Current behavior 😯

Slider thumb cannot be dragged.

### Expected behavior 🤔

Slider should work no matter if one stop propagation in some parent of the Slider

### Context 🔦

The Slider component has a parent way up on the three that needs to prevent propaggation of events. I cannot use the slider :(

### Your environment 🌎

<details>
  <summary><code>npx @mui/envinfo</code></summary>

```
  Don't forget to mention which browser you used.
  Output from `npx @mui/envinfo` goes here.
```
</details>
Repository: vscode
Issue: Integrated console seems lead to a long delay when executing C/C++ code
Labels: bug,tasks

<!-- ⚠️⚠️ 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. -->
<!-- 🔧 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 directly to the extension publisher. The 'Help > Report Issue' dialog can assist with this. -->
- VS Code Version: 1.74.3 x64
- OS Version: Windows 11Pro 22H2 22621.1105

Steps to Reproduce:

1. Install VSCode and Coderunner.
2. Run any C++ code with Code Runner (or anything else that uses the integrated console).

To make things more precise, I also did the following experiments in the latest insider version **without any extensions**:

1. Write a python shell that compiles C/C++ code, executes it immediately, and measures execution duration at the same time. Configure it to be the default build task (which runs in the integrated console).

The compiler args look like
```sh
g++ test.cpp -o test -std=c++17 -O2 -Wall -Wextra -Wconversion -Wshadow -Wl,--stack=1048576000
```
where `test.cpp` looks like
```c++
#include <bits/stdc++.h>

int main() {
    return 0;
}
```
The shell reports that compile finished immediately while the execution holds for about 10 seconds.

2. Remove `-Wl,--stack=1048576000` in compiler args, and do the same things in (1). The execution time was reduced to about 2 seconds, which is still weird but much more acceptable.
3. Manually compile and run `test.cpp` (with compiler args in both (1) and (2)) in the external console in VSCode, and the program exits immediately as expected in both cases.
Repository: opencv
Issue: Incremental PCA
Labels: feature

### Descripe the feature and motivation

Are there any plans to support incremental PCA like in [https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.IncrementalPCA.html#sklearn.decomposition.IncrementalPCA](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.IncrementalPCA.html#sklearn.decomposition.IncrementalPCA) ?

### Additional context

Based on [https://www.cs.toronto.edu/~dross/ivt/RossLimLinYang_ijcv.pdf](https://www.cs.toronto.edu/~dross/ivt/RossLimLinYang_ijcv.pdf)
Repository: vscode
Issue: Add prelaunch Command as well for launch configuration
Labels: feature-request,tasks

<!-- ⚠️⚠️ Do Not Delete This! feature_request_template ⚠️⚠️ -->
<!-- Please read our Rules of Conduct: https://opensource.microsoft.com/codeofconduct/ -->
<!-- Please search existing issues to avoid creating duplicates. -->

<!-- Describe the feature you'd like. -->

As we have "**preLaunchTask**" config to start a task already defined in tasks.json like viz it would be helpful to have something like "preLaunchCommand" as well in which it would not refer to tasks.json rather would directly invoke the command from pre-launch sequence. This would enable users to provide custom input to the command as and when required. 

With tasks defined in task.json it is difficult to send custom input to the task without having a separate prompt (even when it is not required).

Eg: If a launch config is intended for a specific remote IP address and the prelaunch task also required to use the same IP address (variable for different configs) it is not possible to share it to the {"preLaunchTask" : "Task"} directly.
Repository: godot
Issue: Color Picker Button misbehaves after double click
Labels: bug,topic:gui

### Godot version

4.0 beta 14

### System information

Ubuntu 22.04.1 LTS

### Issue description

There is weird behavior when you double click a Color button:

![image](https://user-images.githubusercontent.com/85438892/213744459-e0ddf0f0-6129-46ab-89c3-6aab57cb4ea0.png)

(explained below)

### Steps to reproduce

1. Add, say, a ColorRect. Anything with a Color property
2. Double click the Color Picker button

When you do this, the popup will not close, but some weird things will happen if you try to click away:
- If you then click away somewhere, the popup will close, but if you don't move your mouse, the tooltip of the button will appear.
- If you click while still hovering the button, the popup will close for a fraction of a second, then reappear.

### Minimal reproduction project

N/A it's in the editor
Repository: ant-design
Issue: Search and defaultOpen broken when used in a Modal. Works without using Modal. Works before 4.24.0
Labels: Inactive,4.x,unconfirmed

### Reproduction link

[![Edit on CodeSandbox](https://codesandbox.io/static/img/play-codesandbox.svg)](https://codesandbox.io/s/select-in-modal-with-defaultopen-svj2nc?file=/index.js)

### Steps to reproduce

Open the link.
Check the select is not open by default.

Remove the Modal around Select and it works.

### What is expected?

Select should behave the same inside or outside a modal.

### What is actually happening?

2 issues.
1>Select stays collapsed
2>On Focus it doesnt show the select options.

Focus out and focus in and it works after that.

| Environment | Info |
| --- | --- |
| antd | 4.24.0 |
| React | 18 |
| System | Mac |
| Browser | Chrome latest |

<!-- generated by ant-design-issue-helper. DO NOT REMOVE -->
Repository: pytorch
Issue: API to check for errors in c10d.ProcessGroupNCCL
Labels: oncall: distributed

### 🚀 The feature, motivation and pitch

ProcessGroupNCCL has two options to detect and deal with errors:

1. `NCCL_BLOCKING_WAIT` which is blocking and causes host to device synchronization resulting in perf degradation but raises an appropriate exception in-line in your training code.
2. `NCCL_ASYNC_ERROR_HANDLING` which polls in the background and kills the process if errors are detected.

In certain cases neither of these options are ideal and users would like to inspect ProcessGroup errors themselves and appropriately recover from them if possible.

As a result, the proposal here is to expose an API like `ProcessGroup.hasErrorOrTimedOut` based on which users can take custom actions if an error is indeed discovered. Happy to contribute a PR for this.

### Alternatives

Considered `NCCL_BLOCKING_WAIT` and `NCCL_ASYNC_ERROR_HANDLING` as mentioned above

### Additional context

_No response_

cc @mrshenli @zhaojuanmao @satgera @rohan-varma @gqchen @aazzolini @osalpekar @jiayisuse @H-Huang @kwen2501 @awgu
Repository: create-react-app
Issue: Doesn't work with typescript 4.9 satisfies operator
Labels: needs triage,issue: bug report

### Describe the bug

Doesn't work with the typescript 4.9 `satisfies` operator.

### Steps to reproduce

Add

```ts
const test = {} satisfies {};
```

anywhere in your CRA project.

### Expected behavior

No syntax error.

### Actual behavior

Syntax error.
Repository: kubernetes
Issue: hack/verify-test-code.sh: replace with proper linter
Labels: kind/feature,sig/testing,lifecycle/frozen,area/e2e-test-framework,needs-triage

### What would you like to be added?

A proper linter like something built on https://github.com/quasilyte/go-ruleguard may become a more reliable and capable linter for test guidelines.

- [ ] usage of `framework.ExpectError`
- [ ] avoid the [`Expect.Equal(someBoolean, ...) ` anti-pattern](https://github.com/kubernetes/kubernetes/issues/105678)
- [ ] [gomega annotations](https://onsi.github.io/gomega/#annotating-assertions) support printf-formatting and thus should not be passed the result of fmt.Sprintf

An [enhanced forbidigo](https://github.com/ashanbrown/forbidigo/pull/22) could detect:
- [ ] usage of `wait.Poll` and friends instead of [`gomega.Eventually`](https://github.com/kubernetes/kubernetes/pull/113298)
- [ ] usage of gomega instead of the new [framework.Gomega](https://github.com/kubernetes/kubernetes/pull/113298) inside test/e2e/framework in functions that don't accept a stack offset

import-boss should be used  to
- [x] that test/e2e/framework itself remains light-weight and doesn't import sub-packages


### Why is this needed?

The script uses grep to enforce certain code patterns. This is prone to false negatives. For example, it missed this until the code was changed to be all in one line

test/e2e_node/resource_collector.go:
```
                       gomega.Expect(e2epod.WaitForPodToDisappear(f.ClientSet, f.Namespace.Name, pod.ObjectMeta.Name, labels.Everything(),
                                30*time.Second, 10*time.Minute)).NotTo(gomega.HaveOccurred())
```

The current `test/e2e/framework/.import-restrictions` is probably out-dated.