sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: storybook
Issue: [Bug]: Control for mapped argType doesn't map initial arg on story render
Labels: bug,addon: controls,vue3

### Describe the bug

On Storybook 7 and Vue 3, when using a mapped argType and passing a value to the corresponding arg, the control for the argType renders as if no value was selected.

In other words, the initial arg value is not mapped by the control when it renders, so the control doesn't display the initial arg value as selected.

I deduced that the bug is the control init code not applying the mapping, because if I create a mapping where the ID and label match, then the control properly selects the value.


### To Reproduce

Steps to reproduce the behaviour:
* Create a story for a Vue 3 component
* Add a prop entry to the story's argTypes that includes options and mapping keys and a radio control
* Set a value for that prop in the story's args, matching one of the allowed values
* Open the story in the browser, and notice that the control is rendered with no option selected

Code snippets
```ts
const Button = {
  props: ['variant'],
  template: '{{variant}}',
}

export default {
  argTypes: {
    variant: {
    control: {
        labels: {
            Primary: "Primary",
            Secondary: "Secondary",
        },
        type: "inline-radio"
    },
    mapping: {
        Primary: "primary",
        Secondary: "secondary",
    },
    options: [
        "Primary",
        "Secondary",
    ],
  },
  component: Button,
}

export const Foo = {
  args: {
    variant: "primary", // matches the mapped value!]
  },
}
```


### System

```shell
Environment Info:

  System:
    OS: Linux 6.2 Arch Linux
    CPU: (8) x64 11th Gen Intel(R) Core(TM) i7-1185G7 @ 3.00GHz
  Binaries:
    Node: 16.20.0 - /usr/bin/node
    Yarn: 1.22.19 - /usr/bin/yarn
    npm: 8.19.4 - ~/Development/design-system/node_modules/.bin/npm
  Browsers:
    Firefox: 111.0.1
  npmPackages:
    @storybook/addon-a11y: ^7.0.7 => 7.0.15 
    @storybook/addon-actions: ^7.0.7 => 7.0.15 
    @storybook/addon-essentials: ^7.0.7 => 7.0.15 
    @storybook/addon-interactions: ^7.0.8 => 7.0.15 
    @storybook/addon-links: ^7.0.7 => 7.0.15 
    @storybook/addon-measure: ^7.0.7 => 7.0.15 
    @storybook/addon-storysource: ^7.0.7 => 7.0.15 
    @storybook/addon-viewport: ^7.0.7 => 7.0.15 
    @storybook/addons: ^7.0.7 => 7.0.15 
    @storybook/core-server: ^7.0.7 => 7.0.15 
    @storybook/jest: ^0.1.0 => 0.1.0 
    @storybook/manager-api: ^7.0.11 => 7.0.15 
    @storybook/testing-library: ^0.1.0 => 0.1.0 
    @storybook/theming: ^7.0.11 => 7.0.15 
    @storybook/vue3: ^7.0.7 => 7.0.15 
    @storybook/vue3-vite: ^7.0.7 => 7.0.15
```


### Additional context

_No response_
Repository: rust
Issue: Bad overflow errors on missing trait impls.
Labels: A-diagnostics,T-compiler

### Code

```Rust
use diesel::prelude::*; // diesel 2.0.4, features = ["postgres"]

table! {
    users {
        id -> Integer,
        posts -> Text,
    }
}

fn main() {
    let mut conn = PgConnection::establish("_").unwrap();

    users::table
        .into_boxed()
        .group_by(users::id)
        .load::<(i32, String)>(&mut conn);
}
```


### Current output

```Shell
error[E0275]: overflow evaluating the requirement `_: diesel::Expression`
  --> src/main.rs:13:31
   |
13 |     users::table.into_boxed().group_by(users::id).load::<(i32, String)>(&mut conn);
   |                               ^^^^^^^^
   |
   = help: consider increasing the recursion limit by adding a `#![recursion_limit = "256"]` attribute to your crate (`diesel_multi_test`)
   = note: required for `BoxedSelectStatement<'_, (diesel::sql_types::Integer, diesel::sql_types::Text), FromClause<users::table>, _>` to implement `GroupByDsl<_>`
   = note: 128 redundant requirements hidden
   = note: required for `BoxedSelectStatement<'_, (diesel::sql_types::Integer, diesel::sql_types::Text), FromClause<users::table>, _>` to implement `GroupByDsl<_>` 
```

Note that the relevant trait is not implemented for `BoxedSelectStatement` at all. There exists [a generic impl](https://docs.diesel.rs/2.0.x/diesel/query_dsl/methods/trait.GroupByDsl.html#impl-GroupByDsl%3CExpr%3E-for-T) that does not apply.



### Desired output


Ideally the compiler would emit a trait not implemented error message. 
Other than that the help note that increasing the recursion limit might fix the issue is not helpful as that does not really change anything on the fact that the trait is not implemented. Maybe the compiler could use a heuristic to check if it gets ~recursion limit count times the same error message and skip that suggestion in these cases? Or just skip it if there is a non-default recursion limit (because then the user likely tried to follow that advice already and it did not fix the problem?)



### Rationale and extra context

_No response_

### Other cases

_No response_

### Anything else?

_No response_
Repository: godot
Issue: `Texture2D` has cached `Image` when saving `Resource` to `.tres`
Labels: topic:core,documentation

### Godot version

v4.0.3.stable.official [5222a99f5]

### System information

Mac

### Issue description

I'm trying to write some code that exports a `GridMap` so I can share it between players over the wire.

```gdscript
extends Resource

@export var my_texture: Texture2D
```

Will only output a local reference to the `.godot` cache.

```toml
[sub_resource type="CompressedTexture2D" id="CompressedTexture2D_hogtm"]
resource_local_to_scene = true
load_path = "res://.godot/imported/walls24.png-baee28b6d28cf1eb2ffaf0c01d63a387.ctex"
```

### Steps to reproduce

1. Attempt to save a Resource with a `Texture2D`
2. Check the `.tres`


Instead one has to export an `Image` to get the raw data in the exported file.

This breaks `GridMap` export:

https://github.com/godotengine/godot/issues/23104

### Minimal reproduction project

[test-export.zip](https://github.com/godotengine/godot/files/11572866/test-export.zip)


**Output**
```toml
[gd_resource type="Resource" load_steps=3 format=3]

[sub_resource type="CompressedTexture2D" id="CompressedTexture2D_7j6ik"]
load_path = "res://.godot/imported/icon.svg-218a8f2b3041327d8a5756f3a245f83b.ctex"

[sub_resource type="GDScript" id="GDScript_immgx"]
script/source = "extends Resource

@export var my_texture: Texture2D

func _init() -> void:
	self.my_texture = preload(\"icon.svg\")
"

[resource]
script = SubResource("GDScript_immgx")
my_texture = SubResource("CompressedTexture2D_7j6ik")
```
Repository: vscode
Issue: Settings editor: focus border is cut off
Labels: bug,settings-editor,confirmed


<img width="1408" alt="Screenshot 2023-05-26 at 10 32 44" src="https://github.com/microsoft/vscode/assets/22350/aec258c6-f4bd-4585-930b-5b6ed8698ca4">


cc @roblourens
Repository: TypeScript
Issue: Generating declaration file (.d.ts) for a single module
Labels: Suggestion,Awaiting More Feedback

# Suggestion

## 🔍 Search Terms

So many I can't list them all here, everything related to declaration files, .d.ts generation, .d.ts rollup, import ellision, etc.

## ✅ 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 to generate a `.d.ts` file for a single module.

## 📃 Motivating Example

I currently have a repository which exposes a set of types I need to use in another repo (and for legacy reasons a monorepo isn't possible). The thing is, generating a declaration file for the project will generate declaration for **all modules** inside this project.

What I want is only the declaration of a _specific_ module in that project.

Let's say for instance the project contains `index.ts`, `router.ts` and `schema.ts`. Generating a declaration file will emit declarations for everything exported by these three files. But what I want is only what is exported by `schema.ts`, as it will be used for validation in another repository, whereas the other two files contain business logic that have nothing to do elsewhere, and also depend on packages that won't be available in the other repo.

## 💻 Use Cases

* Exporting specific types to another repository
Repository: next.js
Issue: ⚠ Constent tab crashes when using browser's navigation buttons in soft navigation in app dir - reproduces across projects, envs, browsers and devices
Labels: bug

### Verify canary release

- [X] I verified that the issue exists in the latest Next.js canary release

### Provide environment information

```bash
---
```


### Which area(s) of Next.js are affected? (leave empty if unsure)

Entire app, it's a navigation bug

### Link to the code that reproduces this issue or a replay of the bug

https://github.com/FearlessSlug/nextjs-app-dir-router-bugs

### To Reproduce

**TLDR:** Soft navigate between the pages and then try to slightly spam the browser's back button (it has to be the broswer's navigation buttons!) you will see that the tab freezes and then crashes

I published this nextjs blank project that just has a bunch of different ways to navigate in nextjs app dir, if you soft navigate between the pages (don't go to the 404 pages because they'll do full refresh) and then try to slightly spam the browser's back button you will see that the tab freezes and then crashes, this kind of tab freeze and crash is especialy frequent when using path params hight up in the url, for example when using localization and you need to add /[locale]... to the root of your app directory..
I have tested it on multiple browsers and multiple PCs both locally as well as Vercel hosted, it's consistently crashing and freezing tabs, and keep in mind this is a blank project that has no extra code...
Github repo:
https://github.com/FearlessSlug/nextjs-app-dir-router-bugs
Vercel hosted:
https://nextjs-app-dir-router-bugs.vercel.app/test1 

![2023-05-25-19-23-19-Trim](https://github.com/vercel/next.js/assets/134693517/259013c9-d883-41d7-ba3b-d4112daf4832)

### Describe the Bug

Tab freeze and crash

### Expected Behavior

I expect the tab to not freeze and crash

### Which browser are you using? (if relevant)

Brave, Firefox, Safari (iOS), Edge

### How are you deploying your application? (if relevant)

Vercel
Repository: flutter
Issue: [video_player] Video Progress Indicator bug after first video shown
Labels: p: video_player,package,team-ecosystem,has reproducible steps,P2,found in release: 3.10,found in release: 3.11,triaged-ecosystem

### Is there an existing issue for this?

- [X] I have searched the [existing issues](https://github.com/flutter/flutter/issues)
- [X] I have read the [guide to filing a bug](https://flutter.dev/docs/resources/bug-reports)

### Steps to reproduce

Previewing multiple videos with my code

### Expected results

When i swap from a videoplayer to another, changing controller, the videoprogressindicator should reset and work for the new video

### Actual results

When i swap from a videoplayer to another, changing controller, the videoprogressindicator bugs out completely, showing endless looping of progress on its progress indicator bar. Even tho the visual of the videoprogressindicator is looping endlessly, its scrubbing is still working.

### Code sample

                 if (data.type != 'image') {
                                  if (_controller != null) {
                                    disposevideo();
                                  }
                                  _controller = VideoPlayerController.file(
                                    File(filepost!.path),
                                  )..initialize();
                                  
                                  return Center(
                                      child: AspectRatio(
                                    aspectRatio: _controller!.value.aspectRatio,
                                    child: Stack(
                                      alignment: Alignment.bottomCenter,
                                      children: <Widget>[
                                        VideoPlayer(_controller!),
                                        VideoProgressIndicator(
                                          _controller!,
                                          allowScrubbing: true,
                                          colors: VideoProgressColors(
                                              playedColor: Theme.of(context)
                                                  .primaryColor),
                                        ),
                                        Positioned(
                                            bottom: 0,
                                            left: 0,
                                            child: _playbutton()),
                                      ],
                                    ),
                                  ));


### Screenshots or Video

<details>
<summary>Screenshots / Video demonstration</summary>

[Upload media here]

</details>


### Logs

<details><summary>Logs</summary>

```console
[Paste your logs here]
```

</details>


### Flutter Doctor output

<details><summary>Doctor output</summary>

```console
[Paste your output here]
```

</details>
Repository: go
Issue: cmd/go: go test -fullpath should include full paths for build errors too
Labels: help wanted,Proposal,Proposal-Accepted,GoCommand

<!--
Please answer these questions before submitting your issue. Thanks!
-->

### What version of Go are you using (`go version`)?

<pre>
f90b4cd6554f4f20280aa5229cf42650ed47221d
</pre>

### Does this issue reproduce with the latest release?

N/A


### What did you do?

<!--
If possible, provide a recipe for reproducing the error.
A complete runnable program is good.
A link on go.dev/play is best.
-->

I ran this testscript:

```
! exec go test -C ./x -fullpath .
! stderr '\./x.go'

-- x/x.go --
package foo

var x = mistake

-- go.mod --
module test
```


### What did you expect to see?

A passing test.

### What did you see instead?

```
> ! exec go test -C ./x -fullpath .
[stdout]
FAIL
[stderr]
# test/x
./x.go:3:9: undefined: mistake
[exit status 1]
> ! stderr '\./x.go'
FAIL: /tmp/testscript142857279/x.txtar/script.txtar:2: unexpected match for `\./x.go` found in stderr: ./x.go
```

It seems to me that the intent of `-fullpath` is to cause all filenames to print in a way that's absolute, even when those errors come from the compiler rather than the test binary. I'd expect the compiler error to print an absolute path there too.
Repository: terminal
Issue: Something is, well, probably fine with One half light
Labels: Area-Rendering,Issue-Bug,Product-Terminal

From a mail thread with @jazzdelightsme and @oldnewthing

![image](https://github.com/microsoft/terminal/assets/18356694/62d3195a-95ec-418d-874a-d7391cb7b198)

> 
> Repro:
> 1.	set theme for cmd to “One Half Light”
> 2.	set the “automatically adjust lightness” feature to “always”
> 3.	open a new cmd tab
> 4.	run “pwsh” or “powershell”
> 5.	run “Get-PSReadLineOption”, and notice that several of the colors are invisible (notably the DefaultTokenColor).


---

This is Terminal 1.18, with One Half Light. I’ve typed `git do the thing`. 
![image](https://github.com/microsoft/terminal/assets/18356694/6ea37c3c-f131-4d9b-80dc-1d066d1800ae)


Left: `"adjustIndistinguishableColors": "never", `
right: `"adjustIndistinguishableColors": "always", `

wait, what’s going on here?

 
![image](https://github.com/microsoft/terminal/assets/18356694/ff7d104b-cb24-43f4-a7fe-7d5864a770da)


And the output of conpty looks pretty normal, too. After typing the `o` in `git do`, Terminal gets:
`␛[?25l␛[93m␛[36;27Hgit␣␛[37mdo␣␣␛[36;33H␛[?25h␛[m`

Which is basically:
•	Turn cursor off
•	Use bright yellow FG
•	Cursor to the start of the prompt
•	“git “
•	Use dark white FG
•	“do  “ (two spaces)
•	Move the cursor back a space, turn it back on, and reset the colors. 

Which is exactly what I’d expect. So why is that appearing as white, and not black (which is what bright white is defined as) from the scheme?

Maybe I haven’t had enough coffee yet this morning. 


----

Trawling through the colortool output, I noticed:

```
1;36m␛[38;5;14m␛[3C␣␣gYw␣␣␣␣␣gYw␣␣␣␛[48;5;1m␣␣gYw␣␣␛[49m␣␛[48;5;2m␣␣gYw␣␣␛[49m␣␛[48;5;3m␣␣gYw␣␣␛[49m␣␛[48;5;4m␣␣gYw␣␣␛[49m␣␛[?25l␛[m␛[38;5;14m␛[48;5;5m␣␣gYw␣␣␛[49m␣␛[48;5;6m␣␣gYw␣␣␛[49m␣␛[48;5;7m␣␣gYw␣␣␛[m␍␊

37m␛[5C␣␣gYw␣␣␣␣␣gYw␣␣␣␛[48;5;1m␣␣gYw␣␣␛[m␣␛[48;5;2m␣␣gYw␣␣␛[m␣␛[48;5;3m␣␣gYw␣␣␛[m␣␛[48;5;4m␣␣gYw␣␣␛[m␣␛[48;5;5m␣␣gYw␣␣␛[m␣␛[48;5;6m␣␣gYw␣␣␛[m␣␛[48;5;7m␣␣gYw␣␣␛[m␍␊

1;37m␛[38;5;15m␛[3C␣␣gYw␣␣␣␣␣gYw␣␣␣␛[48;5;1m␣␣gYw␣␣␛[49m␣␛[48;5;2m␣␣gYw␣␣␛[49m␣␛[48;5;3m␣␣gYw␣␣␛[49m␣␛[48;5;4m␣␣gYw␣␣␛[49m␣␛[48;5;5m␣␣gYw␣␣␛[49m␣␛[48;5;6m␣␣gYw␣␣␛[49m␣␛[48;5;7m␣␣gYw␣␣␛[21;1H␛]0;OHL,␣no␣adjust␇␛[?25h␛[m␛[30m␛[107m␍␊
```

* the `37m` line doesn't actually set the foreground color - I think it's relying on the `7` == "default index" thing.
* we're emitting all the colors as 256 color indicies?? good god

Maybe this is related to #15408
Repository: storybook
Issue: [Feature Request]: Excluding img tags from color contrast rule check
Labels: feature request,addon: a11y

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

I have a slider component and because of business reasons I have to show it with real images which violate the color-contrast rule, because I cannot change them. We fetch those images from content management system.

### Describe the solution you'd like

Turn off color-contrast rule for img tags.

### Describe alternatives you've considered

Currently we turn off color contrast rule for the story, but this slider could have a "title" which should be checked with color contrast rule too.

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

no

### Additional context

_No response_
Repository: PowerToys
Issue: Mouse Without Borders and Remote Desktop
Labels: Issue-Bug,Needs-Triage

### Microsoft PowerToys version

0.70.0

### Installation method

PowerToys auto-update, WinGet

### Running as admin

None

### Area(s) with issue?

Mouse Without Borders

### Steps to reproduce

1. Setup two computers using "Mouse Without Borders". _(For me two work computers)_
2. Start a third computer not running Power Toys. _(For me my home computer)_
3. From the third computer remote to one of the computers running "Mouse Without Borders" using "Remote Desktop"
![image](https://github.com/microsoft/PowerToys/assets/85605972/78f91a35-e530-491e-b774-9826fff54b1b)

To get the mouse back was to terminate "Mouse Without Borders"
1. tasklist /S COMPUTER /U USERNAME /P PASSWORD
2. find the PID for "Mouse Without Borders"
3. taskkill /S COMPUTER /U USERNAME /p PASSWORD /PID PID

### ✔️ Expected Behavior

Be able to use the mouse in "Remote Desktop".
For me "Mouse Without Borders" can be turned off when I connect using "Remote Desktop". I can anyway not see the other computer screen and if I need it I remote to that one.

### ❌ Actual Behavior

Mouse pointer disappears

### Other Software

"%windir%\system32\mstsc.exe" (Remote Desktop)

The computer connecting to: Windows 10 Pro 21H2 19044.2965
The computer connecting from: Windows 10 Pro 22H2 19045.2604
Repository: go
Issue: cmd/go: list includes "C" in the Imports field but not in Deps
Labels: NeedsInvestigation,GoCommand

```
$ go version
go version devel go1.21-f90b4cd655 Fri May 26 03:21:41 2023 +0000 linux/amd64
$ go list -f '{{.Imports}}{{"\n"}}{{.Deps}}' runtime/cgo
[C runtime/internal/sys sync sync/atomic unsafe]
[internal/abi internal/bytealg internal/coverage/rtcov internal/cpu internal/goarch internal/godebugs internal/goexperiment internal/goos internal/race runtime runtime/internal/atomic runtime/internal/math runtime/internal/sys runtime/internal/syscall sync sync/atomic unsafe]
```

Note how `runtime/cgo` includes `C` in its `Imports` field, but not in its `Deps` field. 1.20 is the same in this regard:

```
$ go version
go version go1.20.4 linux/amd64
$ go list -f '{{.Imports}}{{"\n"}}{{.Deps}}' runtime/cgo
[C runtime/internal/sys sync sync/atomic unsafe]
[internal/abi internal/bytealg internal/coverage/rtcov internal/cpu internal/goarch internal/goexperiment internal/goos internal/race runtime runtime/internal/atomic runtime/internal/math runtime/internal/sys runtime/internal/syscall sync sync/atomic unsafe]
```

The docs say:

```
        Imports      []string          // import paths used by this package
        Deps         []string          // all (recursively) imported dependencies
```

So I always naively assumed `Imports` to be a strict subset of `Deps`, since one is the set of direct imports, and the other is the set of all direct and indirect package dependencies (transitive imports). However, `C` breaks this rule.

I think `Imports` should stop including `C`, and here are my reasons why:

* Consistency; if `Imports` is not the list of direct dependencies, compared to the list of all transitive dependencies in `Deps`, then how do I get the list of direct dependencies? Right now I'm taking `Imports` and removing `C` from it, which feels hacky.
* `C` is not truly a Go package nor a useful import path; see how `go list C` fails in a funky way (which arguably could be fixed to give a better error, too).
* If a user or tool want to know whether a package uses CGo, they can already consult the `CgoFiles` field, which is clearer and more directly useful.
* `Deps` never included it either, so that's some proof that it's not _really_ needed as a package dependency.

The only reason why one could argue that `Imports` should include `C` is that there really is an `import "C"` in the source code. However, `Imports` is not a direct representation of the import declarations in the source code; they are deduplicated, sorted, and omit any renames like `import foo "bar"` or `import _ "baz"`.