sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: vscode
Issue: Git - Over-under mode for comparing images that have changed
Labels: feature-request,git

<!-- ⚠️⚠️ 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, images can only be shown side-by-side when git detects changes. I work a lot with reference images of visualization software, and you can usually not see the difference this way. Here's an example where I simulate an off-by-one error in a plotting routine. It's impossible to find the problem this way:

<img width="958" alt="image" src="https://github.com/user-attachments/assets/38bd9d16-216d-46c0-b6fd-7c152f33fbe1">

Our brain is really good at change detection though, so why not use that. If we had a button to toggle between "before" and "after" then we'd see this. There's not even a need for something complex like on github, where you can draw a slider left to right or fade back and forth continuously. That kind of makes it harder to spot changes, a simple jump is enough.

![output](https://github.com/user-attachments/assets/6b9f8c85-12a7-4821-9f5b-ebb761b89471)
Repository: next.js
Issue: Impossible to Server-Render Client Components in API Routes
Labels: bug

### Link to the code that reproduces this issue

https://github.com/Titou325/dev-next-ssr

### To Reproduce

1. Start the application
2. Go to http://localhost:3000/api
3. The server errors with 500

### Current vs. Expected behavior

It seems that it is not possible to render "use client" components from API routes. We need to do this to create emails and documents that get sent to a third party.

In basic React, we can just render to readableStream and get the static HTML even for a "use client" component. However, this doesn't seem to work with Next.js, as the component seems to be passed as an empty object.

Server components work fine.

### Provide environment information

```bash
Operating System:
  Platform: darwin
  Arch: arm64
  Version: Darwin Kernel Version 23.6.0: Thu Jun 20 00:25:05 PDT 2024; root:xnu-10063.140.29.0.1~15/RELEASE_ARM64_T6020
  Available memory (MB): 32768
  Available CPU cores: 12
Binaries:
  Node: 20.12.2
  npm: 10.8.0
  Yarn: 1.22.17
  pnpm: 7.14.1
Relevant Packages:
  next: 15.0.0-canary.83 // Latest available version is detected (15.0.0-canary.83).
  eslint-config-next: 14.2.4
  react: 18.3.1
  react-dom: 18.3.1
  typescript: 5.5.3
Next.js Config:
  output: N/A
```


### Which area(s) are affected? (Select all that apply)

Not sure

### Which stage(s) are affected? (Select all that apply)

next dev (local), next build (local), Vercel (Deployed)

### Additional context

I have upgraded to Next canary but still encounter the same discrepancy, with either the react-dom APIs being patched by Next or the component being pre-processed.

While this demo shows something that could be achieved by a page directly, the idea is that we take the HTML string and send it to a third party (in our case [fileforge.com](https://www.fileforge.com/))
Repository: godot
Issue: Behavior of enum types is not properly documented
Labels: topic:gdscript,documentation

### Tested versions

v4.3.beta3.official [82cedc83c]

### System information

w10 64

### Issue description

I don't know if this is a bug.
Nothing happens if you assign a value that is outside the scope of the enum to a variable of type enum.
Maybe a runtime error should happen because the assigned value is not defined in the enum but absolutely nothing happens at any time.

In this example, the value 12 is assigned to a variable of type enum, the enum does not have the value 12 defined in any of its fields.

So what's the point of a variable being an enumeration type?

![Captura6](https://github.com/user-attachments/assets/7f5daafe-fccb-4742-a4aa-2ff7e8871fcc)


### Steps to reproduce

...

### Minimal reproduction project (MRP)

...
Repository: react-native
Issue: RTL Layout Direction Not Updating after app reload with New React Native Architecture
Labels: Issue: Author Provided Repro,Needs: Author Feedback,Type: New Architecture

### Description

When using I18nManager to switch the layout direction between RTL (Right-to-Left) and LTR (Left-to-Right), the changes do not reflect after reload on the UI(doesn't force styles), but apply for animations. This issue appears specifically with the new React Native architecture. The styles and layout directions are only applied correctly after the app is fully restarted.

### Steps to reproduce

1. Set up a React Native project with the new architecture enabled.
2. Use I18nManager.forceRTL(true/false) to change the layout direction and use `react-native-restart`. to restart the app.
3. Observe that the UI does not update immediately(styles not forced to be like `text-align: right`).

### React Native Version

0.74.0

### Affected Platforms

Runtime - iOS, Build - MacOS

### Areas

Fabric - The New Renderer, TurboModule - The New Native Module System, JSI - Javascript Interface, Bridgeless - The New Initialization Flow, Codegen

### Output of `npx react-native info`

```text
System:
  OS: macOS 14.5
  CPU: (10) arm64 Apple M1 Max
  Memory: 272.36 MB / 32.00 GB
  Shell:
    version: "5.9"
    path: /bin/zsh
Binaries:
  Node:
    version: 20.10.0
    path: ~/.nvm/versions/node/v20.10.0/bin/node
  Yarn:
    version: 4.3.1
    path: ~/.nvm/versions/node/v20.10.0/bin/yarn
  npm:
    version: 10.2.3
    path: ~/.nvm/versions/node/v20.10.0/bin/npm
  Watchman:
    version: 2024.07.15.00
    path: /opt/homebrew/bin/watchman
Managers:
  CocoaPods:
    version: 1.15.2
    path: /usr/local/bin/pod
SDKs:
  iOS SDK:
    Platforms:
      - DriverKit 23.5
      - iOS 17.5
      - macOS 14.5
      - tvOS 17.5
      - visionOS 1.2
      - watchOS 10.5
  Android SDK: Not Found
IDEs:
  Android Studio: 2024.1 AI-241.18034.62.2411.12071903
  Xcode:
    version: 15.4/15F31d
    path: /usr/bin/xcodebuild
Languages:
  Java:
    version: 17.0.11
    path: /usr/bin/javac
  Ruby:
    version: 2.6.10
    path: /usr/bin/ruby
npmPackages:
  "@react-native-community/cli": Not Found
  react:
    installed: 18.2.0
    wanted: 18.2.0
  react-native:
    installed: 0.74.0
    wanted: 0.74.0
  react-native-macos: Not Found
npmGlobalPackages:
  "*react-native*": Not Found
Android:
  hermesEnabled: true
  newArchEnabled: true
iOS:
  hermesEnabled: true
  newArchEnabled: true

info React Native v0.74.3 is now available (your project is running on v0.74.0).
info Changelog: https://github.com/facebook/react-native/releases/tag/v0.74.3
info Diff: https://react-native-community.github.io/upgrade-helper/?from=0.74.0
info For more info, check out "https://reactnative.dev/docs/upgrading?os=macos".

```
```


### Stacktrace or Logs

```text
No crush or failure
```


### Reproducer

- https://github.com/serhii-yalla/RTL-Layout-Direction-Not-Updating-after-app-reload-with-New-React-Native-Architecture

### Screenshots and Videos

_No response_
Repository: PowerToys
Issue: Enhancement for PT-Run: Searching/Finding specific Excel Sheets without knowing the Filename where the Sheet is contained
Labels: Idea-Enhancement,Product-PowerToys Run,Needs-Triage,Run-Results (Indexer)

### Description of the new feature / enhancement

Search Sheetnames of Excel files instead of just being able to search excel files. (possibly only not-encrypted files)

### Scenario when this would be used?

**USECASE: I have a lot of excel Files:** i want to find a specific Sheet inside an unknown File without opening all files manually & read all their Sheetnames



### Supporting information

_No response_
Repository: ollama
Issue: Text Generation Documentation
Labels: documentation,feature request,api

Dear all, 

we ❤️ Ollama. Thank you for this great framework. I wa

There are many parameters for text generation Many of such parameters overlap with [llama.ccp](https://github.com/ggerganov/llama.cpp/blob/master/examples/main/README.md#common-options), while few of them do not, e.g.

1. num_thread
2. repeat_last_n
3. num_batch
4. f16_kv

I guess It would be great if you guys could write few sentences.
```
curl http://localhost:11434/api/generate -d '{
  "model": "llama3",
  "prompt": "Why is the sky blue?",
  "stream": false,
  "options": {
    "num_keep": 5,
    "seed": 42,
    "num_predict": 100,
    "top_k": 20,
    "top_p": 0.9,
    "tfs_z": 0.5,
    "typical_p": 0.7,
    "repeat_last_n": 33,
    "temperature": 0.8,
    "repeat_penalty": 1.2,
    "presence_penalty": 1.5,
    "frequency_penalty": 1.0,
    "mirostat": 1,
    "mirostat_tau": 0.8,
    "mirostat_eta": 0.6,
    "penalize_newline": true,
    "stop": ["\n", "user:"],
    "numa": false,
    "num_ctx": 1024,
    "num_batch": 2,
    "num_gpu": 1,
    "main_gpu": 0,
    "low_vram": false,
    "f16_kv": true,
    "vocab_only": false,
    "use_mmap": true,
    "use_mlock": false,
    "num_thread": 8
  }
}'
```
Repository: transformers
Issue: flashattention3
Labels: Feature request

### Feature request

flashattention3 has been released, when will it be supported flashattention3？

### Motivation

use

### Your contribution

pr
Repository: ollama
Issue: Out of Memory Error when using Meta-Llama-3.1-8B-Instruct-Q8_0.gguf model with Ollama ROCm with num_ctx=120000
Labels: bug,amd,memory

### What is the issue?

OS: Linux 6.5.0-44-generic #44~22.04.1-Ubuntu


GPU:



AMD Radeon RX 7900 XTX (24 GiB VRAM)

AMD Radeon RX 7900 XTX (24 GiB VRAM)

AMD Radeon RX 7900 XTX (24 GiB VRAM)


Ollama version: 0.2.8


ROCm module version: 6.7.0
amdgpu-install_6.1.60103-1_all.deb


Model: Meta-Llama-3.1-8B-Instruct-Q8_0


While testing the Meta-Llama-3.1-8B-Instruct-Q8_0.gguf model, I encountered an out of memory error well before reaching the maximum context size of 128k for the model. The model crashes after processing approximately 28,000 tokens, regardless of whether using one GPU with 24GB of memory (nctx = 30,000) or three GPUs with a combined memory of 72GB (nctx = 120,000).


Error:
Jul 25 12:39:17 ailab ollama[683]: CUDA error: out of memory
Jul 25 12:39:17 ailab ollama[683]: current device: 0, in function alloc at /go/src/github.com/ollama/ollama/llm/llama.cpp/ggml/src/ggml-cuda.cu:291
Jul 25 12:39:17 ailab ollama[683]: ggml_cuda_device_malloc(&ptr, look_ahead_size, device)
Jul 25 12:39:17 ailab ollama[683]: GGML_ASSERT: /go/src/github.com/ollama/ollama/llm/llama.cpp/ggml/src/ggml-cuda.cu:101: !"CUDA error"


There might be similar issues, but out of memory errors with multiple GPUs have not been reported yet.

### OS

Linux

### GPU

AMD

### CPU

Intel

### Ollama version

 0.2.8
Repository: godot
Issue: Can't import GLSL shaders in headless mode
Labels: bug,confirmed,topic:import

### Tested versions

4.3.beta.mono.custom_build.ba7c5b0c8

### System information

Godot v4.3.beta.mono (ba7c5b0c8) - Pop!_OS 22.04 LTS - Wayland - Vulkan (Forward+) - dedicated Intel(R) Arc(tm) A750 Graphics (DG2) - AMD Ryzen 7 5800X 8-Core Processor (16 Threads)

### Issue description

Godot currently doesn't support importing glsl shaders in a headless context.  This creates a problem for continuous integration / pipelines.  @clayjohn worded it perfectly in the rocket chat so I'll just quote it here:

> This is a very valuable workflow when you are targeting multiple platforms and becomes super important when working with a team. Basically everyone on the team can work on the platform of their choice, then the CI makes an export build for all target platforms and then you can test release builds on all platforms

> Since CI doesn't have a GPU, you have to be able to import all resources, then export the game without access to a GPU. Ultimately, the game will be played on a device with a GPU, but the import/export process happens without one

This appears to be the PR that disabled glsl imports in headless mode: https://github.com/godotengine/godot/pull/92539

I tried simply reverting that PR and interestingly, it does seem to import the glsl shader.  However, it crashes in the exported project when that shader is loaded if it wasn't previously loaded in a non-headless context.

### Steps to reproduce

1. Clone the proton scatter repo or use the zipped mrp (which is also just the proton scatter repo): https://github.com/HungryProton/scatter.git
2. Open in godot
3. Notice that the trees are loading in the showcase scene.
4. Create an export preset
5. Delete the ``.godot`` folder in the project directory so there aren't any cached imports.
6. Run the command: ``godot --headless --path path/to/project --import``
7. Notice the errors regarding failed glsl imports.
8. Run the command: ``godot --headless --path path/to/project --export-debug PresetName path/to/export/game.exe``
9. Notice the errors regarding glsl
10. Start the exported game and notice that the trees no longer load

### Minimal reproduction project (MRP)

[scatter.zip](https://github.com/user-attachments/files/16377132/scatter.zip)

https://github.com/HungryProton/scatter.git
Repository: three.js
Issue: WebXR not supported on WebGPURenderer
Labels: Enhancement,WebGPU

### Description

As it seems that work on `WebGLRenderer` will go into maintenance mode to make more space for `WebGPURenderer`, it would be great to see an initial implementation of WebXR so we can start testing WebGPU as well. 

We'd like to test and help, but I'm not sure how WebXR fits into the current architecture of the new system with two backends. I'd already be happy if `WebGPURenderer ({forceWebGL: true})` had WebXR support (so, not actually WebGPU).

### Reproduction steps

1. Use WebGPURenderer
2. Try to use XR
3. Note that APIs don't exist anymore (`getSession()`, `getCamera()`, `isPresenting`, ...)

### Version

r167

### Device

Headset, Phones

### OS

Windows, Android
Repository: transformers
Issue: Add New Optimizer
Labels: Feature request

### Feature request

I want to add a new optimizer that I worked on it 
Is there any doc or anything how to add this new optimizer to all files of transformers library?

### Motivation

This optimizer would be great to implement on transformers and reduce time to train a new model 

### Your contribution

I can make a clone of this repo and then changes file and submit PR. But I can't find a document how to implement my algorithm to transformers Files because  I found so much classes and there are a lots of file that need changes.
Repository: pytorch
Issue: [typing] Add missing `__all__` to modules.
Labels: module: optimizer,module: typing,triaged,actionable

### 🚀 The feature, motivation and pitch

`torch` ships with the `py.typed` marker, yet many modules lack a `__all__` declaration. 
This leads to problems with type checkers:

```python
from torch import optim
opt_type = optim.Adam  # pyright: error: "Adam" is not exported from module "torch.optim"
```

According to the [typing spec](https://typing.readthedocs.io/en/latest/guides/libraries.html#library-interface-public-and-private-symbols):

> - Imported symbols are considered private by default
> - A module can expose an `__all__` symbol at the module level that provides a list of names that are considered part of the interface. 

Therefore, modules that reexport symbols such as https://github.com/pytorch/pytorch/blob/main/torch/optim/__init__.py need to declare `__all__`.

cc @vincentqb @jbschlosser @albanD @janeyx99 @crcrpar @ezyang @malfet @xuzhao9 @gramster
Repository: neovim
Issue: Add better built-in support for icons
Labels: enhancement,needs:discussion

### Problem

Usage of icons in modern terminal emulators seems to have come to a point of relatively widespread support. In particular, icons are mostly used for two purposes:
- Indicate type of file in a way that is easier to skim.
- Make more concise display of LSP items kind.

However, currently there is no built-in support in Neovim. For example, there is no built-in way for users/plugins to get an icon for display purposes without installing special plugin icon provider.

### Expected behavior

The purpose of this issue is mostly to be a discussion about acceptable approaches of adding more built-in support for icons.

My current ideas/suggestions:
- Add 'buficon' (as 'icon' is already taken) buffer-local option which can be a source of truth for icon best representing a buffer. It then can be treated the same way as similarly purposed "source of truth" buffer-local options (like, for example, 'commentstring').
- Export Lua function which can return an icon string based on an input data. Similarly to `vim.filetype.match()`.

The lowest friction design seems to be to tie icon to a filetype. This would require to maintain a single table mapping filetype to icon. Similarly to [how it is currently done in 'mini.icons'](https://github.com/echasnovski/mini.nvim/blob/657ef75b52a548090fb7906735517b7ddbf39e88/lua/mini/icons.lua#L861) (but glyph only). Then implementation can roughly be like:
- `vim.filetype.get_icon = function(data) return icons[data.filetype] end`
- Create an autocommand for `FileType` event that sets 'buficon' based on the output of `vim.filetype.get_icon()`.

------

Potential problems with overall idea of adding better built-in support for icons:
- Actually deciding on requirements for potential code points. One approach is to prefer a single Nerd Fonts class and stick with it. Currently `nf-md-*` seems to have the widest range of available icon glyphs.
- Dealing with potential changes in code points. I don't have a solid solution here except suggesting to treat this the same way how LSP protocol updates are currently treated.
- Actually maintaining a table with "filetype -> icon" map. I can provide the initial table. Adding new entries can be as easy as "Check if there is an icon *exactly* for the filetype; if no - use easily computed fallback".
Repository: neovim
Issue: Python legacy vim interface newly raises exception on string with NULL character
Labels: bug,vimscript,channels-rpc

### Problem

With the below source file, between neovim 0.6 and neovim 0.11 something changed in the legacy python implementation so that the`vim.funcs.match` call with a NULL byte in it newly raised an exception.

Not entirely sure what the should/shouldn't choice is here, but it worked before and doesn't work now so raising the bug.
If nothing else it's for visibility and I can link this in the patch where I update my plugin.


### Steps to reproduce

nvim --clean test.vim
(Where test.vim contains the below)
`:source %`
Observe NvimError on second python call.
```
python3 import vim
if has('nvim')
	python3 print(vim.funcs.match('\x01hello', '.hello'))
	" Newly raises python exception.
	python3 print(vim.funcs.match('\x00hello', '.hello'))
else
	python3 print(vim.Function('match')('\x01hello', '.hello'))
	" Original vim (version 9.1 with patches 1-80) complains about embedded NULL byte.
	" ... However ... at the same time original vim converts NULL bytes to
	" newline characters when returning from external channels, so there's
	" precedence for not handling NULL bytes in original vim scripting.
	python3 print(vim.Function('match')('\x00hello', '.hello'))
endif

echo match("\x01hello", '.hello')
" Does not crash, but also does not match.
echo match("\x00hello", '.hello')

"  NVIM v0.11.0-dev-422+g3c803483a
"  Build type: RelWithDebInfo
"  LuaJIT 2.1.1720049189
"  Run ":verbose version" for more info

" With older version ... result matches for python and vimL versions.
" NVIM v0.6.1
" Build type: Debug
" LuaJIT 2.1.0-beta3
" Compilation: /usr/bin/cc -DNVIM_TS_HAS_SET_MATCH_LIMIT -g -Wall -Wextra -pedantic -Wno-unused-parameter -Wstrict-prototypes -std=gnu99 -Wshadow -Wconversion -Wmissing-prototypes -Wimplicit-fallthrough -Wvla -fstack-protector-strong -fno-common -fdiagnostics-color=always -DINCLUDE_GENERATED_DECLARATIONS -D_GNU_SOURCE -DNVIM_MSGPACK_HAS_FLOAT32 -DNVIM_UNIBI_HAS_VAR_FROM -DMIN_LOG_LEVEL=1 -I/home/matthew/repos/neovim/build/config -I/home/matthew/repos/neovim/src -I/home/matthew/repos/neovim/.deps/usr/include -I/usr/include -I/home/matthew/repos/neovim/build/src/nvim/auto -I/home/matthew/repos/neovim/build/include
```

### Expected behavior

Does not raise NvimError.

### Neovim version (nvim -v)

v0.11.0-dev-422+g3c803483a

### Vim (not Nvim) behaves the same?

No -- version of vim tested is 9.1 with patches 1-80

### Operating system/version

Ubuntu 24.04

### Terminal name/version

XTerm(390)

### $TERM environment variable

screen-256color

### Installation

Build from repo
Repository: neovim
Issue: Restart without "close -> open" loop
Labels: enhancement,needs:discussion,complexity:high,startup

### Problem

No way to restart without fully closing and starting with the same command.

See also vim/vim#13904. Decided to open a separate issue here as it seems that implementation will be different and the Vim issue got stale.

### Expected behavior

Available either a `:restart` command or `vim.api.nvim_restart()` function which can restart an instance without "close-reopen" loop.

The effect is expected to be at least the same as (in layman language):
- Do Neovim closing process as normal *but* stop just before actually terminating the process.
- Execute startup sequence as if a new process has started. This can also result in preserving "startup related" data like argument list, CLI options, etc. Maybe even tabpages/windows/buffers for better interactive experience.

I see this feature as useful in at least for following use cases:
- Clean reloading of user config after there were some changes made.
- Restarting instance through RPC without dealing with "close and drop connection -> reopen with proper arguments -> reconnect".
Repository: TypeScript
Issue: Don't allow math operations on different branded numeric types
Labels: Suggestion,Awaiting More Feedback

### 🔎 Search Terms

number numeric branded types plus minus add subtract 

### 🕗 Version & Regression Information

- This is the behavior in every version I tried, and I reviewed the FAQ for entries about Nominal types (tagged, branded)

### ⏯ Playground Link

https://www.typescriptlang.org/play/?#code/C4TwDgpgBAwgrgJwRAdgYxAHgCoD4oC8UKcAtgEYQJQBkUA3lAPpNqLLogBcU2UAvgG4AUKEhQAoogD2hWO1QZMAIggzluEWOgBVAMoAROfCSKsyuAGcAJhpHCAZnHTAAltJRQ0AQxQAFRDQAC29LCABJYAhSAAowBFc0CJQpBGkeVOkAGigAd28AGwKIYHCUfQMeCoBKBmEoBqgAeiaoADlZbSgqNIQc8jhgKHC86TgC6ygQgDdoCAAPSDQoyY8IesbkYERPfKKSsoqofHjE5MyRfmEgA

### 💻 Code

```ts
type Currency<T> = number & { __currency: T };
type Euro = Currency<"euro">;
type USD = Currency<"usd">;

function canPurchaseItem(priceInEuro: Euro, walletInUSD: USD) {
    // No type error, but I would have expected one
    return walletInUSD > priceInEuro;
}
```

### 🙁 Actual behavior

`Euro` and `USD` -two different branded numeric types- can be compared with binary operators such as `-`.

### 🙂 Expected behavior

These are two different branded numeric types. I would have expected that binary operations between the two of them would be disallowed.

More technically, if a mathematical binary operation contains:

* one value that is an intersection of `number` and some object type
* another value that is not assignable to that type

...then I'd expect to receive a type error.

### Additional information about the issue

Per #202, TypeScript doesn't actually formally include a _built-in_ branded/nominal typing. But other mismatched operators are disallowed [[playground of mismatched operators](https://www.typescriptlang.org/play/?#code/MYewdgziA2CmB00QHMAUBtAugAgNTawEoBuAKFEhgSTSz2wG8BfE88KORFDHfARlYUO1bs3oCyQqlzRj8zQe2k1UDbAEMAXNj7Ym9NQCNtAJj2sgA)]:

```ts
// These are all type errors:
console.log([] + []);
console.log([] + {});
console.log([] + 1);
console.log({} + 1);
console.log({} + {});
console.log({ a: 1 } + { b: 2 });
```