sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: go
Issue: cmd/go: follow symlinks referenced by //go:embed
Labels: NeedsInvestigation,GoCommand

<!--
Please answer these questions before submitting your issue. Thanks!
-->

### What version of Go are you using (`go version`)?

<pre>
$ go version
go version go1.20.3 linux/amd64
</pre>

### Does this issue reproduce with the latest release?

Yes

### What operating system and processor architecture are you using (`go env`)?

N/A, applies to any GOOS/GOARCH

### What did you do?

In a Bazel build action running in a symlink-based sandbox, try to build the Go standard library or any third-party package using `//go:embed`.

### What did you expect to see?

The build passes just as it would if the input files weren't symlinks. Tools only play nice with Bazel if they follow symlinks, as whether or not an input file to a Bazel build action is a symlink depends on the particular strategy with which Bazel chooses to execute the action (e.g. remotely or locally, in a sandbox or not, ...).

`//go:embed` not allowing symlinks to be embedded makes sense and I am not asking for that to be changed. However, it would be very helpful if it could be made to *follow* symlinks, either by default or optionally, guarded by a flag or environment variable.

### What did you see instead?

```
external/go_sdk/src/crypto/elliptic/p256_asm.go:24:12: pattern p256_asm_table.bin: cannot embed irregular file p256_asm_table.bin
```

This happens because of the use of `Lstat` in https://github.com/golang/go/blob/3c46d8f5119475adbadb6141acd463b910c1747b/src/cmd/go/internal/load/pkg.go#L2139, which makes symlinks hit the branch at https://github.com/golang/go/blob/3c46d8f5119475adbadb6141acd463b910c1747b/src/cmd/go/internal/load/pkg.go#L2170

This issue requires rules_go to [copy around the stdlib](https://github.com/bazelbuild/rules_go/commit/db9458406295b6f569fc1fa5142483636fb86b45) and [breaks build actions that operate on generated code](https://github.com/bazelbuild/rules_go/issues/3178).
Repository: TypeScript
Issue: Unknown interface "ClassMethodDecoratorFunction" in documentation for 5.0.4 lib.decorators.d.ts
Labels: Bug,Help Wanted

# lib Update Request

## Configuration Check

<!--
  If you're missing common new methods like Array.includes, you may have a misconfigured project.
  Try setting `lib: "es2020"` and checking whether the type you want is present.
  You can diagnose further by running `tsc` with `--listFilesOnly` or `--showConfig`.

  Conversely, if you are seeing built-in methods you expect to *not* see, check your 'lib' setting
  or review your dependencies for lib/reference directives that might be polluting
  your global scope. This is common when using the 'node' type library. See https://github.com/microsoft/TypeScript/issues/40184

  Replace the text below:
-->
My compilation *target* is `ES2021` and my *lib* is `["es2017", "dom"]`.

## Missing / Incorrect Definition

<!--
  What property, method, function, etc is missing or incorrect?
-->
The mentioned [example](https://github.com/microsoft/TypeScript/blob/v5.0.4/src/lib/decorators.d.ts#L97):
```ts
const bound: ClassMethodDecoratorFunction = (value, context) {
  if (context.private) throw new TypeError("Not supported on private methods.");
  context.addInitializer(function () {
    this[context.name] = this[context.name].bind(this);
  });
}
```
Uses an Interface `ClassMethodDecoratorFunction` which isn't implemented - as far as I can tell this should be `ClassMethodDecoratorContext` instead

## Documentation Link
[v5.0.4/src/lib/decorators.d.ts](https://github.com/microsoft/TypeScript/blob/v5.0.4/src/lib/decorators.d.ts#L97)
<!--
  Link to relevant documentation (e.g. MDN, W3C, ECMAScript Spec) to consult for this property.
  Note that lib.dom.d.ts intentionally does not include browser-specific extensions
   or early experimental features.
-->
Repository: deno
Issue: Passing a Request into fetch results in `Content-Length` always set to 0 even when explicitly set
Labels: bug,web

For servers that don't support chunked requests (i.e. [Microsoft Logic Apps](https://learn.microsoft.com/en-us/azure/logic-apps/logic-apps-handle-large-messages)) the typical way of forcing non-chuncked requests is to explicitly set the `Content-Length` header. 

In deno this works when calling fetch directly:

```ts
async function handlePost(request: Request) {
  const data = await request.json();
  const body = JSON.stringify(data);

  const headers = new Headers(request.headers);
  headers.set("Content-Length", body.length.toString());

  const response = await fetch("https://example.com", {
    method: "POST",
    body: body,
    headers,
  });

  return response; 
}
```

The outgoing request `content-length` header is set to the explicitly set length value, i.e. `"21"`.

However, if a new `Request` is created and passed into `fetch` the `Content-Length` header is forced to `0` which then results in the request being sent chunked. This example below is trivial, but we have seen this in the wild when we have a complex app with various middleware, etc. that modify the incoming request.

```ts
async function handlePost(request: Request) {
  const data = await request.json();
  const body = JSON.stringify(data);

  const headers = new Headers(request.headers);
  headers.set("Content-Length", body.length.toString());

  const req = new Request(request.url, {
    method: request.method,
    body: body,
    headers,
  });

  const response = await fetch("https://example.com", req);
  return response;
}
```

The outgoing request `content-length` header is set to `"0"`.

It seems like this change was made here: https://github.com/denoland/deno/issues/15545
Repository: storybook
Issue: [Bug]: Angular: Unable to override Component Providers
Labels: bug,angular,sev:S2

### Describe the bug

If providing providers at the component level they cannot be overridden by the `moduleMetaData({ providers: [] })` option.

### To Reproduce

https://stackblitz.com/edit/github-tgnemy?file=src%2Fstories%2Fbutton.component.ts,src%2Fstories%2FButton.stories.ts&preset=node

### System

```shell
~/projects/github-tgnemy
❯ npx storybook@latest info

Environment Info:

  System:
    OS: Linux 5.0 undefined
    CPU: (8) x64 Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz
  Binaries:
    Node: 16.14.2 - /usr/local/bin/node
    Yarn: 1.22.19 - /usr/local/bin/yarn
    npm: 7.17.0 - /usr/local/bin/npm
  npmPackages:
    @storybook/addon-essentials: ^7.1.0-alpha.11 => 7.1.0-alpha.11 
    @storybook/addon-interactions: ^7.1.0-alpha.11 => 7.1.0-alpha.11 
    @storybook/addon-links: ^7.1.0-alpha.11 => 7.1.0-alpha.11 
    @storybook/angular: ^7.1.0-alpha.11 => 7.1.0-alpha.11 
    @storybook/blocks: ^7.1.0-alpha.11 => 7.1.0-alpha.11 
    @storybook/testing-library: ^0.0.14-next.2 => 0.0.14-next.2 
```
```


### Additional context

_No response_
Repository: pytorch
Issue: Accuracy repro extraction, constants in graph are not preserved exactly
Labels: triaged,oncall: pt2,module: minifier

### 🐛 Describe the bug

If the repro graph contains a constant (e.g., due to use of torch.tensor), this constant is not serialized faithfully when we extract repros. I plan on fixing it so that if the constant is not too big (<= 4) we'll just print it into the graph, but ideally we would use the same ContentStore mechanism to store these constants exactly.

Comment on this issue if this is affecting you.

### Versions

master

cc @msaroufim @bdhirsh @anijain2305 @zou3519 @chauhang @wconstab @ngimel @soumith
Repository: go
Issue: x/vuln: update JSON output to show all locations of a vulnerable symbol
Labels: NeedsInvestigation,vulncheck or vulndb

This is the JSON output for https://github.com/golang/go/issues/59485.
Repository: go
Issue: proposal: testing: Add T.Output() etc
Labels: Proposal

In a test, you often want to mock out the logger. It would be nice to be able to call t.Slog() and get a log/slog logger that send output to t.Log() with the correct caller information.

See https://github.com/neilotoole/slogt for an example of a third party library providing this functionality, but note that it cannot provide correct caller information:

> Alas, given the available functionality on testing.T (i.e. the Helper method), and how slog is implemented, there's no way to have the correct callsite printed.

It seems like this needs to be done on the Go side to fix the callsite.
Repository: next.js
Issue: Issues with hooks from a symlinked directory, integrated via workspaces (npm)
Labels: bug

### Verify canary release

- [X] I verified that the issue exists in the latest Next.js canary release

### Provide environment information

```bash
Operating System:
      Platform: linux
      Arch: x64
      Version: #1 SMP PREEMPT_DYNAMIC Mon May  1 00:55:28 UTC 2023
    Binaries:
      Node: 18.16.0
      npm: 9.6.5
      Yarn: N/A
      pnpm: N/A
    Relevant packages:
      next: 13.3.1
      eslint-config-next: N/A
      react: 18.2.0
      react-dom: 18.2.0
```


### Which area(s) of Next.js are affected? (leave empty if unsure)

`>=13.3.2`

### Link to the code that reproduces this issue

https://github.com/dominikzogg/reproduction-app

### To Reproduce

Use my repo with `master` branch (next: `>=13.3.2`) and its broken, use the `working-version` branch `13.3.1` and it works.


### Describe the Bug

When i upgrade next to >=13.3.2 it produces the following error:

```
../shared/hooks/use-cookie-consent.tsx (10:66) @ undefined
Unhandled Runtime Error
TypeError: dispatcher is null
```

It seems to work if its not symlinked (no issue on my build pipeline where files where copied to the `shared` folder within `project` directory.

I guess its related to: https://github.com/vercel/next.js/pull/48506

### Expected Behavior

I expect that the code runs as it did until 13.3.1

### Which browser are you using? (if relevant)

_No response_

### How are you deploying your application? (if relevant)

_No response_
Repository: electron
Issue: [Bug]: `pagesPerSheet` not respected in `webContents.print()`
Labels: platform/windows,component/printing,bug :beetle:,24-x-y

### 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 bug report that matches the one I want to file, without success.

### Electron Version

24.1.2

### What operating system are you using?

Windows

### Operating System Version

Windows 10

### What arch are you using?

x64

### Last Known Working Electron version

_No response_

### Expected Behavior

I expect the `pagesPerSheet` property on `webContents.print` to be respected

### Actual Behavior

It's not respected

### Testcase Gist URL

https://gist.github.com/c532848444ed21c1868c88a2dcda5205

### Additional Information

Start the app, print to PDF printer or wherever. Notice pagesPerSheet:2 isn't respected. Only one page per sheet is printed
Repository: PowerToys
Issue: Toggle taskabar hide/lock shortcut
Labels: Product-Tweak UI Design

### Description of the new feature / enhancement

A shortcut to toggle automatically hide/ lock taskbar.

### Scenario when this would be used?

While we start a task and require more display area for operations we can easily hide the taskbar. Otherwise we would need taskbar there for multiple purposes like viewing time, managing tabs etc.

### Supporting information

_No response_
Repository: flutter
Issue: [Autosubmit] Enable locking in the implemented queues for autosubmit
Labels: team-infra,P3,triaged-infra

Autosubmit is using a mutex to avoid thread contention when writing fetching and writing configurations to the cache. It will be better to have the cache service to perform the locking.
Repository: PowerToys
Issue: Startup Manager
Labels: Needs-Triage

### Description of the new feature / enhancement

I was thinking if a tab called Startup Manager or something similar to manage all program auto-start functionality. If there can be a simple UI that you can go and add any program and choose if it can startup when Windows starts with current user privileges. The online guides says you can do this with Task scheduler but setting it up it so much hustle and most people failed to accomplish it. The feature should focus on starting a program with no need of user to login, so when a user come, one will sell all listed programs are running before login.
By the say thank you all of you for putting the work on developing PowerToys, really helpful software.

### Scenario when this would be used?

The most useful of feature is when Windows restarts because of installing updates or other reasons then all startup programs have to wait for the user to log in then they lunch from the Startup folder restarts which is almost useless because a user can just start the program at that point, it just saves a click that all. But if the windows restart and you are not there those programs will never start.

### Supporting information

[One of the guide try to solve the problem](https://www.bing.com/ck/a?!&&p=ad0e95a17d3fc64cJmltdHM9MTY4Mjk4NTYwMCZpZ3VpZD0wMTZiMWMwZS0yODE2LTY2YjUtMmE3Ni0wZTdlMjllYjY3MGQmaW5zaWQ9NTE5NA&ptn=3&hsh=3&fclid=016b1c0e-2816-66b5-2a76-0e7e29eb670d&psq=auto+start+programs+in+windows+without+user+login&u=a1aHR0cHM6Ly9zdGFja292ZXJmbG93LmNvbS9xdWVzdGlvbnMvMzE4NTc4NDkvc3RhcnQtYW4tYXBwbGljYXRpb24tYXQtc3lzdGVtLXN0YXJ0LXdpdGhvdXQtbG9naW4&ntb=1)
Repository: storybook
Issue: [Feature Request]: option to `forceRemount` on some arg changes
Labels: feature request,args

### Is your feature request related to a problem? Please describe

Sometime a prop is only important during the first render of a component. That is usually the case for web-components with server side rendered markup, but even for client side rendering, assume a component with a `lazy` prop that depending on it being `true` or `false`, it would download some data or render some markup. Then changing the `lazy` prop from `false` to `true` on an already rendered component, and previously in eager mode doesn't make sense. It would be helpful to remount the whole component when this arg changes.

### Describe the solution you'd like

It can be part of the `argTypes`. e.g.
```js
{
  argTypes: {
    someArg: {
      forceRemount: true,
      // ...
    }
  }
}
```
or even part of the meta config for the whole story if a remount is necessary for any arg change.

### Describe alternatives you've considered

this might be related to https://github.com/storybookjs/storybook/issues/21706

### Are you able to assist to bring the feature to reality?

yes, I can

### Additional context

_No response_
Repository: rust
Issue: rustdoc: synthetic impls don't include bounds that originate from the implementing type
Labels: T-rustdoc,C-bug,A-synthetic-impls,A-auto-traits

For example, given

```rs
pub struct Ty<T: Clone>(T);
```

the impl of the auto trait `Send` synthesized for the generic type `Ty` looks like

```rs
impl<T> Send for Ty<T>
where
    T: Send
```

while ideally its where clause should be `where T: Clone + Send` since in its current form it isn't well-typed: *the trait bound `T: Clone` is not satisfied* (strictly speaking a manual `Send` impl would have to be additionally marked as `unsafe` to be well-formed but the omission is by design).

According to the following paragraph from the PR description of the initial implementation of synthetic impls (#47833):

> All of this means that a user should be able to copy-paste a [synthetic impl] into their code, without any observable changes in behavior (assuming the rest of the program remains unchanged).

If we want to conform to this rule then the current behavior is incorrect (although it goes all the way back to said PR) since a copy-paste will lead to a type error.

Maybe all of this is intentional (less clutter, disk size reduction)? Opening for discussion (my bias: bug).

@rustbot label C-bug T-rustdoc A-auto-traits A-synthetic-impls
Repository: rust
Issue: rustdoc: synthetic impls are faulty in the presence of assoc const equality constraints 
Labels: T-rustdoc,T-compiler,C-bug,A-synthetic-impls,A-auto-traits,F-associated_const_equality

Given

```rs
#![feature(associated_const_equality)]

use std::marker::Unpin; // or any other auto trait

pub struct Outer<T>(Inner<T>);
pub struct Inner<T>(T);

// (A)
impl<const F: bool, T: Trait<FLAG = {F}>> Unpin for Inner<T> {}

// (B)
//impl<T: Trait<FLAG = true>> Unpin for Inner<T> {}

pub trait Trait {
    const FLAG: bool;
}
```

the impl of `Unpin` (or any other auto trait chosen) synthesized for the generic type `Outer` looks like

```rs
impl<T> !Unpin for Outer<T> // for either case, (A) or (B)
//      ^ note the `!`
```

while I expected the impls to be

```rs
// for case (A):
impl<T> Unpin for Outer<T> where T: Trait 
// for case (B):
impl<T> Unpin for Outer<T> where T: Trait<FLAG = true>
```

<details>
<summary>For comparison, the analog involving <b>type</b> equality constraints</summary>

```rs
use std::marker::Unpin; // or any other auto trait

pub struct Outer<T>(Inner<T>);
pub struct Inner<T>(T);

// (A)
impl<F: Bool, T: Trait<Flag = F>> Unpin for Inner<T> {}

//   ---> synthetic impl:
//   impl<T> Unpin for Outer<T> where T: Trait

// (B)
// impl<T: Trait<Flag = True>> Unpin for Inner<T> {}

//   ---> synthetic impl:
//   impl<T> Unpin for Outer<T> where T: Trait<Flag = True>

pub trait Trait {
    type Flag: Bool;
}

pub trait Bool {}
impl Bool for True {}
pub enum True {}

```

</details>

(adding <kbd>T-compiler</kbd> next to <kbd>T-rustdoc</kbd> since `AutoTraitFinder` lives in `rustc`)

@rustbot label C-bug T-rustdoc T-compiler A-auto-traits A-synthetic-impls F-associated_const_equality
Repository: material-ui
Issue: The prop `direction` of `Grid` can only be used together with the `container` prop.
Labels: component: Grid

### 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/sleepy-boyd-x5keb2


### Current behavior 😯

Trying to use `<Grid item direction="column">` will result in the following error
```
Warning: Failed prop type: The prop `direction` of `Grid` can only be used together with the `container` prop.
```

However, there are valid cases where one would want to apply this prop to a grid item, without having "container" prop there as well. One such example would be to create a grid like so: 

<img width="791" alt="Screenshot 2023-05-02 at 20 36 57" src="https://user-images.githubusercontent.com/3663640/235742132-2c697afa-c322-4ca0-9299-cd995ac13cf1.png">

In the repro I provided the code I've used to achieve this layout. Requires only one style override (to card height), while using only available props otherwise. It would be preferable to be able to avoid using SX prop, or writing overrides manually if necessary styles can be applied using existing props.

If there's another way to achieve this layout, I'd love to know. Cheers

### Expected behavior 🤔

It should allow to apply direction prop also when `item` prop is present.

### Context 🔦

_No response_

### Your environment 🌎

_No response_
Repository: PowerToys
Issue: "Move windows between zones across all monitors" doesn't skip monitors with no defined zones
Labels: Issue-Bug,Needs-Triage

### Microsoft PowerToys version

0.69.1

### Installation method

GitHub

### Running as admin

No

### Area(s) with issue?

FancyZones

### Steps to reproduce

There is an option in FancyZones called "Move windows between zones across all monitors" but it does not make the function skip monitors that do not have any zones defined.

### ✔️ Expected Behavior

To only move windows between monitors that do have defined zones and ignore those without such zones.

### ❌ Actual Behavior

Windows are moved across all connected monitors, not just those with defined zones.

### Other Software

_No response_
Repository: TypeScript
Issue: `moduleResolution: bundler` diverges from bundlers following node semantics in regards to `default` import
Labels: Suggestion,Awaiting More Feedback

# Bug Report

### 🔎 Search Terms

moduleResolution bundler node webpack default namespace

### 🕗 Version & Regression Information

- This is the behavior in every version I tried: 5.0.4 (the only one with `moduleResolution: bundler`

### ⏯ Playground Link

Repro case can be found [here](https://github.com/Andarist/import-reexporting-cjs-bundlers/commit/c41f9256cf3153107226664456f667672fcd64ae)

### 🙁 Actual behavior

When resolving a `.d.mts` file that proxies to `.d.ts` in a CJS package with `moduleResolution: bundler`, TypeScript complains with an error like:
> `Property 'default' does not exist on type 'string'.ts(2339)`

The reason that it complains about it is that TypeScript is resolving `default` import as if the `.d.ts` in this CJS package could export the "real" default export. webpack actually follows semantics coined by node and it loads the **namespace** object as the `default` export of that "cjs file".

So the type-level reality diverges there from runtime. At runtime, with webpack - it works exactly like it would work in node. TypeScript thinks that the intention was to load `module.exports.default` there though.

### 🙂 Expected behavior

I'm not exactly sure what's the expected behavior here because "resolving" like a bundler is quite under-specified and bundlers are not quite consistent when it comes to this. Even when we check this very same repro, we can see that I had to use `defaultIsModuleExports: true` in Rollup for it to behave the same. By default, Rollup behaves in the same way as TypeScript does.

cc @andrewbranch