sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: TypeScript
Issue: Allow for optional index signatures (for the sake of `exactOptionalPropertyTypes`)
Labels: Suggestion,Awaiting More Feedback

# Bug Report

<!--
  Please fill in each section completely. Thank you!
-->

### 🔎 Search Terms

<!--
  What search terms did you use when trying to find an existing bug report?
  List them here so people in the future can find this one more easily.
-->

`exactOptionalPropertyTypes` `strictoptionalProperties` `Partial` index signature dictionary record

### 🕗 Version & Regression Information

<!-- When did you start seeing this bug occur?

"Bugs" that have existed in TS for a long time are very likely to be FAQs; refer to
  https://github.com/Microsoft/TypeScript/wiki/FAQ#common-bugs-that-arent-bugs

If possible, please try testing the nightly version of TS to see if it's already been fixed.
For npm: `typescript@next`
This is also the 'Nightly' version in the playground: http://www.typescriptlang.org/play/?ts=Nightly

Note: The TypeScript Playground can be used to try older versions of TypeScript.

Please keep and fill in the line that best applies:
-->
- This is the behavior in every version I tried, and I reviewed the FAQ for entries about `exactOptionalPropertyTypes`

### ⏯ Playground Link

<!--
  A link to a TypeScript Playground "Share" link which shows this behavior

  The TypeScript Workbench can be used for more complex setups, try
  https://www.typescriptlang.org/dev/bug-workbench/

  As a last resort, you can link to a repo, but these will be slower for us to investigate.
-->
[Playground link with relevant code](https://www.typescriptlang.org/play?exactOptionalPropertyTypes=true#code/C4TwDgpgBAsiBKEDGB7ATgEygXigbygA8AuKAZ2DQEsA7AcwG4oAvUi6+qAXwYChfUNClDSkACgEM0wKhIA2AHjiJUmAHw58vKDqKkARCH0AabboD05qAFE0adFAlkoEQpCTAIWQKDkZnaygAVxoMCAAzWi9THn5QSFgQABEqD00CAG0AawgQNkpaOgBdPI46bj4BFCFgKAxxKRl5JSSU4A1cPD89KEMTLssbN2RPLAg7BwAjQJq6FBqaKuhAGXIugODQiJoo3h4gA)

### 💻 Code

<!-- Please post the relevant code sample here as well-->
```ts
type MyRecord = { x: string; z: string };

const r: Partial<MyRecord> = {
    x: "y",
    // Error as expected ✅
    z: undefined,
};

type MyDict = { [key: string]: string };

const d: Partial<MyDict> = {
    x: "y",
    // Expected error but got none ❌
    z: undefined,
};
```

### 🙁 Actual behavior

See code comments above.

### 🙂 Expected behavior

See code comments above.

---

This was briefly discussed in https://github.com/microsoft/TypeScript/issues/44524 and https://github.com/microsoft/TypeScript/issues/44421#issuecomment-859053118.
Repository: go
Issue: x/playground: some popup examples aren't worth including
Labels: NeedsDecision

The new version of the Go playground includes the following examples:

- Hello, World!
- Conway's Game of Life
- Fibonacci Closure
- Peano Integers
- Concurrent Pi
- Concurrent Prime Sieve
- Peg Solitaire Solver
- Tree Comparison
- Clear Screen
- HTTP Server
- Display Image
- Multiple Files
- Sleep
- Test Function
- Generic min

Some of these are important and useful demonstrations of the playground's capabilities, and useful building blocks for people to use as a starting point for their own examples. In that category, I'd include these:

- Hello, World! - gotta start somewhere
- Clear Screen - a playground-specific capability
- HTTP Server - showing that it's OK to run a network-based program
- Display Image - another playground-specific capability
- Multiple Files - demonstrates the txtar format and local modules
- Sleep - showing it's OK to sleep
- Test Function - we can define test functions too
- Generic min - generics available here!

I believe the other examples are less useful - they add clutter to the useful examples, and some of them demonstrate practices that are theoretically interesting but probably not a good idea in practice. In that latter category I'd include the following:

- Fibonacci Closure
- Peano Integers
- Concurrent Pi
- Concurrent Prime Sieve
- Tree Comparison

While the above are all interesting, I don't believe they deserve the privileged place in the playground that they currently occupy. For example, it's common for newcomers to Go to overuse channels in situations that they're not really suited for, and using them in examples like "Concurrent Pi", "Concurrent Prime Sieve" and "Tree Comparison" probably won't help in that regard.

I'd suggest that we restrict the examples in the playground to those that demonstrate playground-specific capabilities or act usefully as building blocks for examples that people might build. In other words, let's remove the above set of examples from the pop-up, please :smiley: .

As an alternative, maybe include a link to a page showing other examples with playground links, which would allow each link to be framed by some explanation and could scale to include many more possible examples.
Repository: electron
Issue: [Feature Request]: Stopping the crash reporter
Labels: enhancement :sparkles:

### Preflight Checklist

- [X] I have read the [Contributing Guidelines](https://github.com/electron/electron/blob/main/CONTRIBUTING.md) for this project.
- [X] I agree to follow the [Code of Conduct](https://github.com/electron/electron/blob/main/CODE_OF_CONDUCT.md) that this project adheres to.
- [X] I have searched the [issue tracker](https://www.github.com/electron/electron/issues) for a feature request that matches the one I want to file, without success.

### Problem Description

Generally for anything that can be started there should be a way to stop it, the crashReporter has no method for stopping it.

Practical use case: my app collects some telemetry events, if users decide they don't want those collected the crash reporter must be stopped too to comply with their decision, which is currently not possible.

### Proposed Solution

Implement crashReporter#stop.

### Alternatives Considered

Not using the crash reporter? Although I would lose crash reports that way, and there's no other way to collect those.

### Additional Information

_No response_
Repository: storybook
Issue: Addons: error Converting circular structure to JSON for Angular mat-table
Labels: question / support,has workaround,angular,args

**Describe the bug**
When MatTableDataSource is used in addons arguments, the story is broken
```
const dataSource = new MatTableDataSource(ELEMENT_DATA);

export const Primary = Template.bind({});
Primary.args = {
  testDataSource: dataSource
}
```
```
vendors~main.a935f15a2179a6eff5fd.manager.bundle.js:2 TypeError: Converting circular structure to JSON
    --> starting at object with constructor 'MapSubscriber'
    |     property '_parentOrParents' -> object with constructor 'Subscriber'
    |     property '_subscriptions' -> object with constructor 'Array'
    --- index 0 closes the circle
    at JSON.stringify (<anonymous>)
    at ObjectControl (main.991fa6e71cce7c92d381.manager.bundle.js:1)
    at oh (vendors~main.a935f15a2179a6eff5fd.manager.bundle.js:2)
    at Rj (vendors~main.a935f15a2179a6eff5fd.manager.bundle.js:2)
    at Qj (vendors~main.a935f15a2179a6eff5fd.manager.bundle.js:2)
    at Kj (vendors~main.a935f15a2179a6eff5fd.manager.bundle.js:2)
    at yj (vendors~main.a935f15a2179a6eff5fd.manager.bundle.js:2)
    at vendors~main.a935f15a2179a6eff5fd.manager.bundle.js:2
    at exports.unstable_runWithPriority (vendors~main.a935f15a2179a6eff5fd.manager.bundle.js:2)
    at cg (vendors~main.a935f15a2179a6eff5fd.manager.bundle.js:2)
```


**To Reproduce**
1. Generate angular component with Angular material table <table mat-table [dataSource]="dataSource">
2. Create a story for the component where args will contain a data for mat-table dataSource as new MatTableDataSource(ELEMENT_DATA)
=> story load is broken

Repo:
https://github.com/Tatsianacs/storybook--bug

**System**
Environment Info:

  System:
    OS: Windows Server 2016 10.0.14393
    CPU: (6) x64 Intel(R) Core(TM) i7-5820K CPU @ 3.30GHz
  Binaries:
    Node: 16.13.0 - C:\Program Files\nodejs\node.EXE
    Yarn: 3.1.1 - ~\node_modules\.bin\yarn.CMD
    npm: 8.1.0 - C:\Program Files\nodejs\npm.CMD
  Browsers:
    Chrome: 95.0.4638.69
  npmPackages:
    @storybook/addon-actions: ^6.4.2 => 6.4.2 
    @storybook/addon-essentials: ^6.4.2 => 6.4.2 
    @storybook/addon-links: ^6.4.2 => 6.4.2 
    @storybook/angular: ^6.4.2 => 6.4.2 
    @storybook/builder-webpack5: ^6.4.2 => 6.4.2 
    @storybook/manager-webpack5: ^6.4.2 => 6.4.2 

**Additional context**
It doesn't work at least for Controls and accessibility addons, it worked for Knobs and nothing is broken if addon is disabled OR dataSource is removed from the table (workaround:  
```
dataSource: {
			table: {
				disable: true,
			}
		}
```
Repository: rust
Issue: [ER] Warn against impls that don't need to take mutable &self
Labels: C-enhancement,A-lints,A-diagnostics,T-compiler

The Rust compiler gives a very useful warning for variables that don't need to be mutable. This is more than just tidyness, such little things could sometimes reveal a bug nearby:

```rust
fn main() {
    let mut x: u32 = 10;
    println!("{}", x + 20);
}


warning: variable does not need to be mutable
 --> ...\test.rs:2:9
  |
2 |     let mut x: u32 = 10;
  |         ----^
  |         |
  |         help: remove this `mut`
  |
  = note: `#[warn(unused_mut)]` on by default
```

So I'd like rustc to give a similar warning for impls:

```rust
struct Foo { x: u32, y: u32 }

impl Foo {
    fn bar(&mut self) -> u32 {
        self.x
    }

    fn spam(&mut self) -> u32 {
        self.bar() + self.y
    }
}

fn main() {
    let mut f = Foo { x: 0, y: 1 };
    println!("{}", f.spam());
}
```

Here I'd like rustc to give two warnings here, that explain that both bar() and spam() don't need to take self as mutable.

Currently to solve this problem I just replace all "&mut self" with "&self" and restore the ones that cause compilation errors. Sometimes this needs to be iterated because like in the example spam() can't be &self unless first bar() becomes &self. But this method is brutal and it's the job of the compiler.

Note that currently rustc gives those warnings for value self:

```rust
#[derive(Copy, Clone)]
struct Foo { x: u32, y: u32 }

impl Foo {
    fn bar(mut self) -> u32 {
        self.x
    }

    fn spam(mut self) -> u32 {
        self.bar() + self.y
    }
}
```
Repository: angular
Issue: JSON Schema for tsconfig.app.json or tsconfig.json
Labels: feature,area: compiler,feature: under consideration

### Which @angular/* package(s) are relevant/releated to the feature request?

_No response_

### Description

It would be nice if I could specify a `$schema` for the `tsconfig.app.json` (or `tsconfig.json` depending on your setup) provided by the Angular package. This would give us autocompletion, inline documentation via the `description` field and type validation for each parameter, especially important for `angularCompilerOptions`.

### Proposed solution

A `schema.json` file inside the `@angular` package that can be set as `$schema` for the `tsconfig.app.json`, as is already the case for the `angular.json`.
Repository: pytorch
Issue: torch.stack should have a pin_memory parameter
Labels: triaged,module: memory format

## 🚀 Feature
torch.stack should have a pin_memory parameter: `torch.stack(tensors, dim=0, *, out=None, pin_memory=False)`

## Motivation

`torch.stack` "Concatenates a sequence of tensors along a new dimension." This usually means that data is copied from different locations to one memory location. After having assembled a batch of images with `torch.stack`, I want to copy it to the GPU as fast as possible. To enable non-blocking transfer, the tensor has to be in pinned memory. But to to that, the data has to be copied into pinned memory first. This is one copy too much.

## Pitch

`torch.stack` should have a `pin_memory` parameter so that the individual data pieces are copied directly into pinned memory.

## Alternatives

Currently, I'm using the following:

```python
def stack_ex(
    tensors: Union[Tuple["torch.Tensor"], List["torch.Tensor"]], pin_memory: bool = False
):
    n_tensors = len(tensors)
    first = tensors[0]
    size = (len(tensors),) + first.size()
    out = torch.empty(size, dtype=first.dtype, pin_memory=pin_memory)
    torch.stack(tensors, out=out)
    return out
```

But I don't know how efficient that is.


cc @VitalyFedyunin @jamesr66a
Repository: yt-dlp
Issue: fox.com.tr which airsTurkey series, news, shows [not fox.com]
Labels: site-request

### Checklist

- [X] I'm reporting a new site support request
- [X] I've verified that I'm running yt-dlp version **2021.12.01**. ([update instructions](https://github.com/yt-dlp/yt-dlp#update))
- [X] I've checked that all provided URLs are alive and playable in a browser
- [X] I've checked that none of provided URLs [violate any copyrights](https://github.com/ytdl-org/youtube-dl#can-you-add-support-for-this-anime-video-site-or-site-which-shows-current-movies-for-free) or contain any [DRM](https://en.wikipedia.org/wiki/Digital_rights_management) to the best of my knowledge
- [X] I've searched the [bugtracker](https://github.com/yt-dlp/yt-dlp/issues?q=) for similar issues including closed ones. DO NOT post duplicates
- [X] I've read the [guidelines for opening an issue](https://github.com/yt-dlp/yt-dlp/blob/master/CONTRIBUTING.md#opening-an-issue)
- [X] I've read about [sharing account credentials](https://github.com/yt-dlp/yt-dlp/blob/master/CONTRIBUTING.md#are-you-willing-to-share-account-details-if-needed) and am willing to share it if required

### Region

Global

### Example URLs

- Single video: https://www.fox.com.tr/Ask-Mantik-Intikam/bolum/22
- Playlist: https://www.fox.com.tr/Ask-Mantik-Intikam/bolumler

### Description

This website airs new episodes of Turkish dramas,News, Programs

### Verbose log

```shell
$ yt-dlp -Uv https://www.fox.com.tr/Ask-Mantik-Intikam/bolum/22
[debug] Command-line config: ['-Uv', 'https://www.fox.com.tr/Ask-Mantik-Intikam/bolum/22']
[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, err utf-8, pref UTF-8
[debug] yt-dlp version 2021.12.01 [91f071af6]
[debug] Python version 3.9.7 (CPython 64bit) - Linux-5.13.0-22-generic-x86_64-with-glibc2.34
[debug] exe versions: ffmpeg 4.4 (setts), ffprobe 4.4, rtmpdump 2.4
[debug] Optional libraries: Cryptodome, keyring, mutagen, sqlite, websockets
[debug] Proxy map: {}
Latest version: 2021.12.01, Current version: 2021.12.01
yt-dlp is up to date (2021.12.01)
[debug] [generic] Extracting URL: https://www.fox.com.tr/Ask-Mantik-Intikam/bolum/22
[generic] 22: Requesting header
WARNING: [generic] Falling back on generic information extractor.
[generic] 22: Downloading webpage
[generic] 22: Extracting information
[debug] Looking for video embeds
ERROR: Unsupported URL: https://www.fox.com.tr/Ask-Mantik-Intikam/bolum/22
Traceback (most recent call last):
  File "/home/yashoswal/.local/lib/python3.9/site-packages/yt_dlp/YoutubeDL.py", line 1329, in wrapper
    return func(self, *args, **kwargs)
  File "/home/yashoswal/.local/lib/python3.9/site-packages/yt_dlp/YoutubeDL.py", line 1398, in __extract_info
    ie_result = ie.extract(url)
  File "/home/yashoswal/.local/lib/python3.9/site-packages/yt_dlp/extractor/common.py", line 597, in extract
    ie_result = self._real_extract(url)
  File "/home/yashoswal/.local/lib/python3.9/site-packages/yt_dlp/extractor/generic.py", line 3813, in _real_extract
    raise UnsupportedError(url)
yt_dlp.utils.UnsupportedError: Unsupported URL: https://www.fox.com.tr/Ask-Mantik-Intikam/bolum/22
```
Repository: neovim
Issue: Completion API: completion handlers, Lua callbacks on completion events
Labels: enhancement,api,lua,completion

## Feature description

#13854 adds support for general-purpose fuzzy filtering of completion candidates, but I've been recently thinking about ways to make this more general, and allow plugins to have more control over the completion process beyond just filtering. More specifically, I'm proposing an API such as the following:

```lua
vim.api.nvim_completion_attach(mode, {
  on_init = function(line, index)
    -- returns the index where completion should start, like omnifunc
  end,
  on_fetch = function(prefix)
    -- returns a list of completion candidates, overriding the current completion list.
  end,
  on_fetch_chain = function(prefix)
    -- returns a list of completion candidates, which are then appended to the current completion list.
  end
  on_filter = function(prefix, match)
    -- returns a float representing the match between prefix and match.
    -- higher numbers are sorted first in the completion list.
  end,
  on_select = function(match)
    -- called when a completion candidate is selected.
  end,
  on_accept = function(match)
    -- called when a completion candidate is accepted.
  end,
  on_cancel = function() end,
})
```
where `mode` is one of the builtin completion modes, such as `CTRL_X_{NORMAL, FILES, TAGS}`, etc.

As follow up work, we can also allow for custom user completion modes via a new api function `nvim_complete`, which is also implemented in #13854:

```
vim.api.nvim_completion_attach("user:git", ...)
vim.api.nvim_complete(1, {"git", "files", "here"}, {completion_mode = "git"})
```

I'm posting this issue to try and get feedback on whether this is even a good idea or not, and general API design, before I start writing anything.
Repository: ant-design
Issue: Table component, incorrect calculation of "left" position of fixed column
Labels: Inactive

- [ ] 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/modest-torvalds-1o3l8?file=/src/App.js)

### Steps to reproduce
Create a table with multiple columns, and set the first 3 columns to be fixed. 
Then set a cell of the second column to return `colSpan: 0` (*so that it is not rendered*), and in the same row make the 3rd column to be `colSpan: 2` (*so that it occupies the previous space of column 2*).




### What is expected?
The 3rd column in that row should occupy the 2nd and 3rd cells (*normal table works like that*)

### What is actually happening?
Notice that the second column is left blank, instead of being filled by the 3rd column. This seems to happen due to the columns being fixed and the calculation of `left` position does not account for the hidden column.

| Environment | Info |
|---|---|
| antd | 4.17.2 |
| React | 17.0.2 |
| System | macOS BigSur |
| Browser | Firefox 94.0.2 / Chrome 96.0.4664.55 / Any  |

---
If you remove the `fixed` prop from the columns, you will see that the layout works as expected (*since they are not positioned*).


<!-- generated by ant-design-issue-helper. DO NOT REMOVE -->
Repository: pytorch
Issue: [ROCM] elementwise kernel launch
Labels: module: rocm,triaged,Stale

## Issue description
ROCM will compile two kernels when launching some element wise kernels after the following pr https://github.com/pytorch/pytorch/pull/67294 . 

For example elementwise kernels in aten/src/ATen/native/cuda/LinearAlgebra.cu and aten/src/ATen/native/cuda/ScatterGatherKernel.cu

@micmelesse @jeffdaily are working on a solution.

cc @jeffdaily @sunway513 @jithunnair-amd @ROCmSupport @KyleCZH
Repository: PowerToys
Issue: Shortcuts for screen rotation
Labels: Idea-New PowerToy,Product-Display management

### Description of the new feature / enhancement

Could you give shortcuts for screen rotation? Because computers with a AMD Readon Graphics Card can't have a shortcuts like `Ctrl+Alt+→`. 

### Scenario when this would be used?

Screen rotation

### Supporting information

_No response_
Repository: go
Issue: x/build/cmd/relui: standalone runability for private CI pipelines to create installers
Labels: Builders,NeedsInvestigation,FeatureRequest

<!--
Please answer these questions before submitting your issue. Thanks!
For questions please use one of our forums: https://github.com/golang/go/wiki/Questions
-->
Trying to set up private branch/fork/clone releases, so our local devs can build some OSS Go programs both in CI and locally off of the the branch without having to build from source. See [r/golang/comments/r55ysn/is_the_build_system_for_the_base_go_binaries/](https://www.reddit.com/r/golang/comments/r55ysn/is_the_build_system_for_the_base_go_binaries/)

The build system repo has several parts and describes running each build process inside buildlets. But one component the cmd/release doesn't seem to rely on the buildlet cmd, so I'm curious if I could use that directly in a CI pipeline to build the few installers/packages of our fork that we need?
I'm needing to make a few of the packages/installers, like the ones available for standard Go (that bundle the tooling, path, and config changes), for distribution to our devs and other build systems so they don't have to build from source, and can have a similar install experience without added complexity on their end.
Repository: TypeScript
Issue: Fails to perform type narrowing on functions that return "never"
Labels: Suggestion,Awaiting More Feedback

# Bug Report

### 🔎 Search Terms

type narrowing never

### 🕗 Version & Regression Information

- v4.5.2
- v4.4.4
- v4.3.5
- v4.2.3
- v4.1.5
- v4.0.5
- v3.9,7
- This is the behavior in every version I tried, and I reviewed the FAQ for entries about this.

### ⏯ Playground Link

[Playground link with relevant code](https://www.typescriptlang.org/play?ts=4.5.2#code/C4TwDgpgBAygFgewK4BsAmA5CA3CAnAJQmCTwDsAxJMgY2AEsEyoBeKACgEpWA+KMnPgDcAWABQ4lMSgBnRKkyDCxUmQBcseeiy5lJclVoMmUAD79UKVhZQpREsQDNqdRs0cIEXDQN1QA3uJQUPSOHHLI2kpE+sws8TYo3IFiwcHAcHgIAO78ELkAonhZeOwA5AAqcNAARBEKOvgxqjVQzkZuUNkAhjL8CMAhZPQM3Sj0AF4QaAB0ZZz2wQC+4kGyWoq6zeRc9itiQA)

### 💻 Code

```ts
type ShouldNeverReturnFunction = () => never;

let shouldNeverReturn: ShouldNeverReturnFunction | null = null;

function foo(): never {
  if (shouldNeverReturn === null) {
    throw new Error('The "shouldNeverReturn" function was not initialized.');
  }

  shouldNeverReturn();
}
```

### 🙁 Actual behavior

The TypeScript compiler refuses to compile this code.

### 🙂 Expected behavior

I expect the TypeScript compiler to compile this code.

The error message says that the `foo` function has "a reachable end point", but that is clearly false, so the TypeScript compiler seems to be drunk. 🍺🥴
Repository: flutter
Issue: Developers should be discouraged from having unlabeled leaf a11y nodes
Labels: a: tests,c: new feature,framework,a: accessibility,P3,team-framework,triaged-framework

For example, the following should trigger a test error:

```dart
await tester.pumpWidget(
  MaterialApp(
    home: Scaffold(
      body: Column(
        mainAxisAlignment: MainAxisAlignment.center,
        children: [
          const Text(
            'You have pushed the button this many times:',
          ),
          Text(
            '5',
            style: Theme.of(context).textTheme.headline4,
          ),
          Image.network('https://via.placeholder.com/150'),
        ],
       ),
    ),
  ),
);
```

The error should tell the developer that they should either provide a semantic label for the image, or exclude it from semantics. Otherwise screen readers may focus on the image and not have an appropriate thing to read out, which is frustrating for a11y users.

I think we should do this in `testWidgets`, with a walk of the a11y tree that checks for unlabeled/hinted/valued leaf nodes. It could be done as an a11y matcher, but ideally this is something tests would get opted into to catch errors that developers tend to miss in this regard.

/cc @goderbauer @chunhtai