sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: flutter
Issue: Consider using Freetype for font rendering in flutter_tester's software renderer (for goldens)
Labels: a: tests,framework,c: proposal,P3,team-engine,triaged-engine

PROBLEM DESCRIPTION

Currently, we use platform-specific font renderers (e.g. CoreText on macOS, DirectWrite on Windows). We do this even with the software renderer in flutter_tester, which we use for golden tests. This leads to platform differences even with the Ahem font, e.g.:

![macOS and Windows render text differently](https://github.com/flutter/flutter/assets/551196/bc215c02-12d9-4d06-85ce-271f077c80e4)

(This is [comparing macOS and Windows](https://flutter-gold.skia.org/search?corpus=flutter&include_ignored=false&left_filter=name%3Dmaterial.date_picker.dialog.contents.visible.0.88&max_rgba=0&min_rgba=0&negative=true&not_at_head=false&positive=true&reference_image_required=false&right_filter=&sort=descending&untriaged=true) in otherwise identical situations.)

PROPOSAL

We could use Freetype everywhere we do golden testing (i.e. in flutter_tester regardless of platform). This might reduce the number of differences between platforms, which would aid significantly in letting us generate goldens on any platform and have them work everywhere.

We wouldn't want to do this for the builds we ship to users, since it would increase the download size and would reduce the platform fidelity (people are sensitive to how fonts are rendered across apps on their platform).
Repository: go
Issue: os: TestStartProcess failures
Labels: NeedsInvestigation

```
#!watchflakes
default <- pkg == "os" && test == "TestStartProcess"
```

Issue created automatically to collect these failures.

Example ([log](https://ci.chromium.org/b/8749944411124129025)):

    === RUN   TestStartProcess
    === PAUSE TestStartProcess
    === CONT  TestStartProcess
        os_test.go:1250: Can't find pwd: exec: "pwd": executable file not found in $PATH
    --- FAIL: TestStartProcess (0.00s)


— [watchflakes](https://go.dev/wiki/Watchflakes)
Repository: storybook
Issue: [Bug]: jsxDEV is not a function on production build with @storybook/react-vite 8.0.7
Labels: bug,needs triage

### Describe the bug

This only occurs during production build.

It works when build with `NODE_ENV=\"development\" storybook build`


### To Reproduce

I have a monorepo with multiple projects. It occurs on every projects.
Will see if I can create a repro.

### System

```bash
Storybook Environment Info:

  System:
    OS: macOS 14.4.1
    CPU: (10) arm64 Apple M1 Pro
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 20.12.2 - ~/.nvm/versions/node/v20.12.2/bin/node
    npm: 10.5.0 - ~/.nvm/versions/node/v20.12.2/bin/npm
    pnpm: 9.0.4 - ~/.nvm/versions/node/v20.12.2/bin/pnpm <----- active
  Browsers:
    Chrome: 124.0.6367.62
    Safari: 17.4.1
```


### Additional context

_No response_
Repository: pytorch
Issue: When using DDP, model outputs that are are custom dataclasses would make things silently wrong
Labels: oncall: distributed

### 🐛 Describe the bug

https://github.com/pytorch/pytorch/blob/501edc7e590c967fe2b416011a1a0aaa6790e60b/torch/nn/parallel/distributed.py#L1575-L1585

In DDP's post forward, we are flattening the model outputs and apply some DDP specific logic for flattened components. However this does not account for custom data class types, where user need to explicitly register a pytree node to flatten out the tensors inside.

Today if user just use s custom dataclass as model outputs, DDP would silently be wrong.

I think we should error out if there's no pytree node registered for the tree_flattened results that are custom data types.

### Versions

main branch

cc @mrshenli @pritamdamania87 @zhaojuanmao @satgera @rohan-varma @gqchen @aazzolini @osalpekar @jiayisuse @H-Huang @kwen2501 @awgu @penguinwu @fegin @XilunWu @fduwjj @wz337 @tianyu-l @wconstab @yf225 @chauhang @d4l3k
Repository: godot
Issue: OccluderInstance3D baking does not ignore ShaderMaterials that are transparent
Labels: bug,topic:rendering,topic:3d

### Tested versions

4.2.2-stable

### System information

Windows 10 (I don't think this matters at all)

### Issue description

According to @Calinou, the OccluderInstance3D only checks for if a SurfaceMaterial has the transparency flag. Instead it should read the cull mode defined in the Shader, which should be even easier to read, according to him.

This should also be applied to the Lightmapper.

CC @Calinou @clayjohn 

### Steps to reproduce

Create a MeshInstance3D with the shader included as the MRP as the material. Observe as it fails to be ignored by the OccluderInstance3D

### Minimal reproduction project (MRP)

[glass.zip](https://github.com/godotengine/godot/files/15069029/glass.zip)
Repository: ollama
Issue: ilsp/Meltemi-7B-Instruct-v1-GGUF request
Labels: model request

Hi ollama team. Is it possible to ilsp/Meltemi-7B-Instruct-v1-GGUF model in the repository. Thanks in advance
Repository: rust
Issue: Support `rustc_confusables` on items other than methods
Labels: A-diagnostics,T-compiler,A-suggestion-diagnostics,D-papercut,D-terse

As a follow up #120730, `#[doc(alias = "name")]` and `#[rustc_confusables(..)]` should be supported on all items, so that the following

```rust
#[doc(alias = "plus")]
fn add(a: i32, b: i32) -> i32 { a + b }

fn main() {
    let _ = plus(1, 2);
}
```

the resolve error for `plus` should mention `add` as well.
Repository: angular
Issue: Add support for using functions as pipes
Labels: area: core,core: pipes

### Which @angular/* package(s) are relevant/related to the feature request?

core

### Description

Currently, in order to create a custom pipe, there is a good amount of boiler-plate code. You need to add the `@Pipe` decorator to an entire class that you create, just so you can extend `PipeTransform` and implement what often ends up being a small transformation or piece of logic.

This is reminiscent of the old `CanActivate(Children)` and `CanDeactivate(Children)` classes, which were deprecated in favor of `Can(De)ActivateFn`. I am suggesting making a similar change for pipes, which would allow devs to reduce the amount of boilerplate code they have to write as well as allowing devs to keep small or extremely specific pipes within the class files they're used, since the function could just be defined on the class.

### Proposed solution

Creating a `PipeFn` class which defines the inputs/outputs required for a function to work as a pipe, and allow functions to be used as a pipe in lieu of entire classes.

### Alternatives considered

An alternative would be modifying the `@Pipe` decorator so that it can be used on classes or functions, or creating a different decorator for functions to mark them as pipes.
Repository: three.js
Issue: FBXLoader loads default Unreal model with wrong rotation
Labels: Loaders

### Description

Here are two FBX models, one from Mixamo, one from Unreal:

https://rawcdn.githack.com/trusktr/assets/fe18e72007bafeaa6d37f3c4a5816fd3da63e413/mixamo-michele.fbx
https://rawcdn.githack.com/trusktr/assets/fe18e72007bafeaa6d37f3c4a5816fd3da63e413/unreal-manny.fbx

In Blender, they both load in the correct upright orientation, but in Threejs the Unreal model loads in an orientation off by 90 degrees.

### Reproduction steps

Create a scene that loads both models.

### Code

```js
new FBXLoader().load('https://rawcdn.githack.com/trusktr/assets/fe18e72007bafeaa6d37f3c4a5816fd3da63e413/unreal-manny.fbx', model => {
	model.position.x += 50
	scene.add(model)
})

new FBXLoader().load('https://rawcdn.githack.com/trusktr/assets/fe18e72007bafeaa6d37f3c4a5816fd3da63e413/mixamo-michele.fbx', model => {
	model.position.x -= 50
	scene.add(model)
})
```


### Live example

https://codepen.io/trusktr/pen/JjVwvNo

### Screenshots

Screenshot of Blender (I spaced the characters apart or else they would overlap):

<img width="638" alt="Screenshot 2024-04-22 at 3 28 30 PM" src="https://github.com/mrdoob/three.js/assets/297678/72b4cf4f-6b4f-49b8-a362-0407c4bbeab7">

Screenshot of Threejs (each model moved apart by 100 "centimeters"):

<img width="414" alt="Screenshot 2024-04-22 at 4 03 07 PM" src="https://github.com/mrdoob/three.js/assets/297678/219c325d-dc4a-48b3-94ac-78da517c0400">




### Version

r163

### Device

_No response_

### Browser

_No response_

### OS

_No response_
Repository: flutter
Issue: [web:a11y] input.value test is a noop
Labels: engine,a: accessibility,platform-web,P2,team-web,triaged-web

Just noticed, while working on something else, that we have this line in our tests:

https://github.com/flutter/engine/blob/aeb987bce6ecf47e15de33ca7c0b0f85b6a0eb42/lib/web_ui/test/engine/semantics/semantics_test.dart#L1773

It is attempting to check that the `<input>` element has a value of "hello". However, because `outerHTML` strips away the `value` property, the test results in a false positive. The `value` is actually empty.

I'm not yet sure if this is a bug, but I'm filing this to leave a TODO and look into it later.
Repository: godot
Issue: Sluggish interface on Mobile and Forward+
Labels: bug,topic:rendering,topic:editor,needs testing,regression,topic:2d,performance

### Tested versions

- reproducible in 4.2.2, not reproducible in 4.2.1 and 4.2

### System information

Godot v4.2.2.stable - Windows 10.0.22631 - GLES3 (Compatibility) - NVIDIA GeForce RTX 4060 (NVIDIA; 31.0.15.5123) - Intel(R) Core(TM) i3-10100F CPU @ 3.60GHz (8 Threads)

### Issue description

I was working on a project on 4.2.1, proceeded to download 4.2.2, after opening project on 4.2.2 the editor interface was sluggish when switching tabs or adding nodes to the scene, and when running the game with F5, the loading was slightly slower.
This also happens with an empty/new project.
This only happens in Mobile and Forward+

### Steps to reproduce

Create a new project on 4.2.2 in compatibility mode, create some nodes, interact with the editor, mainly in menus and settings.
Now switch to mobile or forward+ and it should be noticeably slower, theres noticeable delay for actions to happen, id guess 100-400ms

### Minimal reproduction project (MRP)

[test.zip](https://github.com/godotengine/godot/files/15069611/test.zip)
Repository: rust
Issue: `E0716` suggests `binding` on 1st assign, rather than merge
Labels: A-diagnostics,T-compiler

### Code

```Rust
#[allow(unused)]
fn main() {
    let x = 0;
    let y;
    y = &&x;
    println!("{y}");
}
```


### Current output

```Shell
Compiling playground v0.0.1 (/playground)
error[E0716]: temporary value dropped while borrowed
 --> src/main.rs:5:10
  |
5 |     y = &&x;
  |          ^^- temporary value is freed at the end of this statement
  |          |
  |          creates a temporary value which is freed while still in use
6 |     println!("{y}");
  |               --- borrow later used here
  |
help: consider using a `let` binding to create a longer lived value
  |
5 ~     let binding = &x;
6 ~     y = &binding;
  |

For more information about this error, try `rustc --explain E0716`.
error: could not compile `playground` (bin "playground") due to 1 previous error
```


### Desired output

```Shell
Compiling playground v0.0.1 (/playground)
error[E0716]: temporary value dropped while borrowed
 --> src/main.rs:5:10
  |
5 |     y = &&x;
  |          ^^- temporary value is freed at the end of this statement
  |          |
  |          creates a temporary value which is freed while still in use
6 |     println!("{y}");
  |               --- borrow later used here
  |
help: consider using a `let` binding to create a longer lived value
  |
4 ~     let y = &&x;
  |

For more information about this error, try `rustc --explain E0716`.
error: could not compile `playground` (bin "playground") due to 1 previous error
```


### Rationale and extra context

In "Desired output" IDK what's the proper notation to express "delete line 5"

### Other cases

_No response_

### Rust Version

```Shell
Playground
1.79.0-nightly
2024-04-21
fb898629a26e4acec59c
```


### Anything else?

https://github.com/rust-lang/rust/issues/99430#issuecomment-2071134933
Repository: pytorch
Issue: Unbacked SymInts: Should backwards graph with unbacked SymInts be recompiled with hints
Labels: triaged,oncall: pt2,module: dynamic shapes

### 🐛 Describe the bug

While working on https://github.com/pytorch/pytorch/issues/124652 I discovered that when we have a tensor with data-dependent size saved for backwards, we end up with symbolic sizes that are unbacked as inputs to the graph.

Now, if we ahead of time compile the backwards graph, there is no way to deal with these inputs. However, if we were willing to delay compilation (e.g., because backwards had to be delayed, or perhaps https://docs.google.com/document/d/1EHEMwSzBPOsmk0EDztRXlGwEo_TizVc5jkW_5Gp5eRs/edit#heading=h.moip2jp9ghoz ) we could give hints to all of these integers, as we'd waited long enough to actually see what their values are.

Should we do this?

### Versions

main

cc @msaroufim @bdhirsh @anijain2305 @chauhang
Repository: opencv
Issue: interpolation blend colors even when fully transparent
Labels: question (invalid tracker),category: imgproc

### System Information

OpenCV python version: 4.9.0.80
Operating System / Platform: Windows 10
Python version: 3.11.2

### Detailed description

when using any type of interpolation the border matches background color, which is expected, the problem is that even when the background alpha is 0, it is still blending the others RGB channels

### Steps to reproduce

```import cv2
import numpy as np
import math
from PIL import Image, ImageDraw

height = 100
width = 500

image =  Image.new("RGBA", (width, height), (0, 0, 0, 0))
draw = ImageDraw.Draw(image)
draw.rounded_rectangle((5, 5, width-5, height-5), fill='#0000ff', radius=10)

image = np.array(image.getdata(), dtype=np.uint8).reshape(height, width, 4)

angleInDegrees = 4

h, w = image.shape[:2]
img_c = (w / 2, h / 2)

rot = cv2.getRotationMatrix2D(img_c, angleInDegrees, 1)

rad = math.radians(angleInDegrees)
sin = math.sin(rad)
cos = math.cos(rad)
b_w = math.ceil((h * abs(sin)) + (w * abs(cos)))
b_h = math.ceil((h * abs(cos)) + (w * abs(sin)))

rot[0, 2] += ((b_w / 2) - img_c[0])
rot[1, 2] += ((b_h / 2) - img_c[1])

outImg = cv2.warpAffine(image, rot, (b_w, b_h), flags=cv2.INTER_LINEAR)

out_pil = Image.fromarray(outImg)
bg =  Image.new("RGBA", out_pil.size, (255, 255, 255, 255))
bg.paste(out_pil, (0, 0), out_pil)
```
![black](https://github.com/opencv/opencv/assets/57723873/56884b74-c831-43fe-a8ea-9ba6fe253d10)
```
image =  Image.new("RGBA", (width, height), (255, 0, 0, 0))
```
![red](https://github.com/opencv/opencv/assets/57723873/f48d5824-cefe-4ce5-8cce-01bec1403c95)
```
image =  Image.new("RGBA", (width, height), (0, 255, 0, 0))
```
![green](https://github.com/opencv/opencv/assets/57723873/fb1eb694-1fec-44e4-9840-79a304bfb7cb)


zoom in the images to see


### Issue submission checklist

- [X] I report the issue, it's not a question
- [X] I checked the problem with documentation, FAQ, open issues, forum.opencv.org, Stack Overflow, etc and have not found any solution
- [X] I updated to the latest OpenCV version and the issue is still there
- [X] There is reproducer code and related data files (videos, images, onnx, etc)
Repository: vscode
Issue: Terminal suggest snippets
Labels: feature-request,terminal-suggest

I'd like if vscode's shell integration allowed injecting command aliases from the `settings.json` file. It would be really helpful to allow projects with a range of shells/os's to share a common set of commands

### Settings.json
```json
{
  "terminal.integrated.shellIntegration.aliases":  {
    "gp": "git push"
  }
}
```

### Pwsh Injected Command
```ps1
function __VSCode-<aliasName>() {
  <aliasCommand> $args
}
Set-Alias -Name '<aliasName>' -Value '__VSCode-<aliasName>'
```

### Bash/Fish/Zsh Injected Command
```sh
alias <aliasName>='<aliasCommand>'
```
Repository: go
Issue: proposal: slices: add IndexPointer
Labels: Proposal

### Proposal Details

I propose the addition of:
```go
// IndexPointer returns the index of the element in s that p points to.
// It returns -1 if p is not found in s.
func IndexPointer[S ~[]E, E any](s S, p *E) int
```

A use of this is to check whether some slice is a subslice of another slice, by checking:
`len(subslice) > 0 && slices.IndexPointer(s, &subslice[0]) >= 0`

Such an operation is useful:
- As an optimization, where knowing that one slice is a directly subslice of another allows you to skip certain operations
- As a means of precondition error checking where an operation will produce invalid results if one argument is a subslice of another. For example, `AppendFoo(dst, src)` is will produce corrupt data if `src` is a subslice of `dst` and the operation writes more bytes to `dst` than it reads from `src`. Such bugs are difficult to track down and ideally the API can return an error by detecting such situations (or just clone the `src` for a slower but correct implementation).

An alternative API is:
```go
func ContainsSubslice[S ~[]E, E any](s S, subslice S) bool
```
but:
1. This is easy to hold wrong since both `s` and `subslice` are of type `S`.
2. It has weird edge cases where `s` and `subslice` overlap, but neither is subslice of the other.
3. Returning a `bool` is strictly less flexible than returning an index.
4. The naming isn't clear what the definition of "Contains" means. Is it comparing the _value_ of the elements? The naming of `IndexPointer` is more clear about it's meaning.

### Implementation

The naive implementation is straight forward:
```go
func IndexPointer[S ~[]E, E any](s S, p *E) int {
	for i := range s {
		if p == &s[i] {
			return i
		}
	}
	return -1
}
```
but is unfortunately non-performant as it performs an O(n) search over the slice.

A more efficient implementation takes advantage of pointer arithmetic:
```go
func IndexPointer[S ~[]E, E any](s S, p *E) int {
	i := 0
	if p != nil && unsafe.Sizeof(*p) > 0 {
		pd := unsafe.Pointer(unsafe.SliceData(s))
		pe := unsafe.Pointer(p)
		i = int((uintptr(pe) - uintptr(pd)) / unsafe.Sizeof(*p))
	}
	if uint(i) < uint(len(s)) && p == &s[i] {
		return i
	}
	return -1
}
```
which can now compute the result in O(1).

Without the helper function in "slices", it is currently impossible in Go to identify whether a given slice is a sub-slice of another slice in O(1) without the use of "unsafe". By including this helper in the "slices" package, callers can avoid the use of "unsafe" to perform this operation.
Repository: next.js
Issue: Flashing UI loading when multiple redirects
Labels: Upstream,bug,Lazy Loading,Performance

### Link to the code that reproduces this issue

https://github.com/paqstd-dev/nextjs-flashing-loading-redirects

### To Reproduce

1. Install depends & run project:
```bash
npm i
npm run build && npm run start
```

2. Open http://localhost:3000
3. Click link "Page 1"

### Current vs. Expected behavior

Currently, during redirect, the `loading` component is unmounted before the next content is loaded. This causes the content to flicker. I deliberately added bright colors so that it would be clearly visible.

Expected the loading was run all the time until the page, or other loading, was ready to be displayed. This content will change instantly. 

I would like to look into this, since this problem was discovered on a production project.

### Provide environment information

```bash
Operating System:
  Platform: darwin
  Arch: arm64
  Version: Darwin Kernel Version 23.4.0: Fri Mar 15 00:10:42 PDT 2024; root:xnu-10063.101.17~1/RELEASE_ARM64_T6000
  Available memory (MB): 16384
  Available CPU cores: 10
Binaries:
  Node: 21.6.2
  npm: 10.2.4
  Yarn: N/A
  pnpm: 8.10.2
Relevant Packages:
  next: 14.2.2 // Latest available version is detected (14.2.2).
  eslint-config-next: N/A
  react: 18.2.0
  react-dom: 18.2.0
  typescript: 5.4.5
Next.js Config:
  output: N/A
```


### Which area(s) are affected? (Select all that apply)

Lazy Loading, Performance, Upstream

### Which stage(s) are affected? (Select all that apply)

next dev (local), next start (local), Vercel (Deployed)

### Additional context

https://github.com/vercel/next.js/assets/26341266/f4ec1a84-0b5c-4cb8-b253-8f2da80f99e6

Deployed on Vercel:
https://nextjs-flashing-loading-redirects-39ldw6h77-paqstd.vercel.app
Repository: vscode
Issue: API to provide a terminal for use with `run-in-terminal` request
Labels: feature-request,debug

<!-- ⚠️⚠️ 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. -->

Currently, `run-in-terminal` creates a terminal or uses one already created. For python we have scenarios where we need "activated" terminals that use specific version of python from an environment. The activation process might also involve running some scripts. The request here is to have an API that extensions can use to contribute a terminal. The idea is that when `run-in-terminal` needs a terminal, and the debug session was started by python extension, then python extension can create and activate the terminal as needed and provide that terminal to `run-in-terminal`. This will allow the python extension to dynamically provide terminals as needed based on the environment selected.