sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: pytorch
Issue: pytorch dataloader has function that raises error
Labels: module: dataloader,triaged,module: data

### 🐛 Describe the bug

I have been getting errors when trying to train a model in pytorch. I am pretty new so it might be something that i have to do but i decided to go follow the error and I got to the function __next__ inside the file .venv/Lib/site-packages/torch/util/data/dataloader.py

Inside the __next__ function it will unconditionally call the _next_data function. The next data function has one line which is
`raise NotImplementedError`

I think this may be causing my problem and I thank anyone in advance who replies.

### Versions

Collecting environment information...
PyTorch version: 2.3.1+cpu
Is debug build: False
CUDA used to build PyTorch: Could not collect
ROCM used to build PyTorch: N/A

OS: Microsoft Windows 11 Home
GCC version: Could not collect
Clang version: Could not collect
CMake version: Could not collect
Libc version: N/A

Python version: 3.12.3 (tags/v3.12.3:f6650f9, Apr  9 2024, 14:05:25) [MSC v.1938 64 bit (AMD64)] (64-bit runtime)
Python platform: Windows-11-10.0.22631-SP0
Is CUDA available: False
CUDA runtime version: 12.5.40
CUDA_MODULE_LOADING set to: N/A
GPU models and configuration: GPU 0: NVIDIA GeForce RTX 4060
Nvidia driver version: 556.12
cuDNN version: Could not collect
HIP runtime version: N/A
MIOpen runtime version: N/A
Is XNNPACK available: True

CPU:
Architecture=9
CurrentClockSpeed=2100
DeviceID=CPU0
Family=198
L2CacheSize=24576
L2CacheSpeed=
Manufacturer=GenuineIntel
MaxClockSpeed=2100
Name=13th Gen Intel(R) Core(TM) i7-13700F
ProcessorType=3
Revision=

Versions of relevant libraries:
[pip3] numpy==1.26.4
[pip3] torch==2.3.1
[conda] Could not collect

cc @andrewkho @gokulavasan @SsnL @VitalyFedyunin @dzhulgakov
Repository: pytorch
Issue: Dynamo errors on `import ... as ...`
Labels: triaged,oncall: pt2,module: dynamo

The test will break if I change the assignment to an `as` import.

```python
# SUCCESS
from optree import PyTreeSpec
TreeSpec = PyTreeSpec

# FAILURE
from optree import PyTreeSpec as TreeSpec
```

These two are semantic equivalents. There must be something broken in Dynamo. I can reproduce this on the main branch. cc @ezyang @anijain2305 @chauhang @penguinwu @voznesenskym @EikanWang @jgong5 @Guobing-Chen @XiaobingSuper @zhuhaozhe @blzheng @wenzhe-nrv @jiayisunx @chenyang78 @kadeng @amjames @jansel

_Originally posted by @XuehaiPan in https://github.com/pytorch/pytorch/issues/130141#issuecomment-2227346243_
Repository: godot
Issue: Godot application does not focus the window when launched from another client (itch, editor, steam, etc)
Labels: bug,platform:windows,topic:porting

### Tested versions

- Reproducible in Godot v4.2.2

### System information

Godot v4.2.2.stable - Windows 10.0.22631 - Vulkan (Forward+) - dedicated NVIDIA GeForce RTX 2060 (NVIDIA; 32.0.15.5599) - AMD Ryzen 5 5600X 6-Core Processor (12 Threads)

### Issue description

Upon enabling my application to target fullscreen, I choose either fullscreen or exclusive fullscreen. Upon launch of the application either in the editor via F5 or from Itch.io after deployment the game's window does not have focus, but rather the client that initially launched the window does.

### Steps to reproduce

1. Go to Project > Project Settings > Window 
2. set to Fullscreen or Exclusive Fullscreen
3. F5 or build and run from Itch.io (after deployment)
4. Editor/other client app still has focus

### Minimal reproduction project (MRP)

https://github.com/obscurelyme/Test-Fullscreen
Repository: ollama
Issue: Request to add support for InternVL-2 model
Labels: model request

It is hoped that the ollama platform can add the model InternVL-2 series.
Repository: deno
Issue: ERR_MULTIPLE_CALLBACK is thrown during running `test` script in commander.js repo
Labels: bug,node compat

Steps to reproduce:

- clone https://github.com/tj/commander.js
- run `DENO_FUTURE=1 deno install`
- run `deno task test`

3 cases fail with `Jest worker encountered 4 child process exceptions, exceeding retry limit`, and the root cause of them seems `error: Uncaught Error: Callback called multiple times` during running each case. That error seems thrown at https://github.com/denoland/deno/blob/main/ext/node/polyfills/_stream.mjs#L3986

```
error: Uncaught Error: Callback called multiple times
Error: 
    at new ERR_MULTIPLE_CALLBACK (ext:deno_node/internal/errors.ts:1225:17)
    at onwrite (ext:deno_node/_stream.mjs:3986:32)
    at Writable.write [as _write] (ext:deno_node/_process/streams.mjs:43:7)
    at writeOrBuffer (ext:deno_node/_stream.mjs:3956:16)
    at _write (ext:deno_node/_stream.mjs:3901:14)
    at Writable.write (ext:deno_node/_stream.mjs:3904:14)
    at Object.writeOut (<anonymous>:23305:31)
    at Object.write (<anonymous>:28122:42)
    at Command.outputHelp (<anonymous>:28213:13)
    at Command._outputHelpIfRequested (<anonymous>:28498:12)
    at Command._parseCommand (<anonymous>:26225:10)
    at Command.parse (<anonymous>:25279:10)
    at Object.<anonymous> (<anonymous>:52:15)
    at Promise.then.completed (<anonymous>:298:28)
    at new Promise (<anonymous>)
    at callAsyncCircusFn (<anonymous>:231:10)
    at _callCircusTest (<anonymous>:316:40)
    at Object.runMicrotasks (ext:core/01_core.js:642:26)
    at processTicksAndRejections (ext:deno_node/_next_tick.ts:53:10)
    at runNextTicks (ext:deno_node/_next_tick.ts:71:3)
    at eventLoopTick (ext:core/01_core.js:175:21)
    at async _runTest (<anonymous>:252:3)
    at async _runTestsForDescribeBlock (<anonymous>:126:9)
    at async _runTestsForDescribeBlock (<anonymous>:121:9)
    at async run (<anonymous>:71:3)
    at async runAndTransformResultsToJestFormat (<anonymous>:122:21)
    at jestAdapter (file:///Users/kt3k/oss/commander.js/node_modules/.deno/jest-circus@29.7.0/node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapter.js:79:19)
    at runTestInternal (file:///Users/kt3k/oss/commander.js/node_modules/.deno/jest-runner@29.7.0/node_modules/jest-runner/build/runTest.js:367:16)
    at runTest (file:///Users/kt3k/oss/commander.js/node_modules/.deno/jest-runner@29.7.0/node_modules/jest-runner/build/runTest.js:444:34)
    at Object.worker (file:///Users/kt3k/oss/commander.js/node_modules/.deno/jest-runner@29.7.0/node_modules/jest-runner/build/testWorker.js:106:12)
```


Version: Deno 1.45.2
Repository: puppeteer
Issue: [Bug]: Intercepting the request cannot find the host in the headers
Labels: bug,confirmed,P3

### Minimal, reproducible example

```TypeScript
const puppeteer = require('puppeteer');

(async () => {
  const browser = await puppeteer.launch({ headless: false, devtools: true });
  const page = await browser.newPage();

  // 监听请求事件
  page.on('request', request => {
    const headers = request.headers();
    console.log(headers)
    if (headers['host']) {
      console.log('Request URL:', request.url());
      console.log('Request Headers:', headers);
    } else {
      console.log('Host header not found in the request to:', request.url());
    }
  });

  // 导航到一个页面
  await page.goto('http://172.18.253.134/');

  await browser.close();
})();
```


### Background

When I intercept the request, I cannot find the host in the headers, but I can see it after devtools is opened.

![80a38087-656d-4ee3-ac38-ef1af62a63d4](https://github.com/user-attachments/assets/5e148bc7-719e-4960-81c2-8ec022d55cc7)
![963b8a50-53fb-4b7a-b79f-efbb9fb0d768](https://github.com/user-attachments/assets/1b678335-42f8-4916-88f8-a8fe1ac4fef2)


### Expectation

I hope that host and other information can be written in the headers when intercepting the request.

### Reality

Intercepting the request cannot find the host in the headers

### Puppeteer configuration file (if used)

_No response_

### Puppeteer version

22.8.1

### Node version

v20.13.1

### Package manager

npm

### Package manager version

10.5.2

### Operating system

Windows
Repository: tensorflow
Issue: TF timeline timestamp was shifted. The resultant timeline cannot be shown correctly in chrome tracing viewer
Labels: stat:awaiting tensorflower,type:bug,comp:core,TF 2.12

### Issue type

Bug

### Have you reproduced the bug with TensorFlow Nightly?

Yes

### Source

binary

### TensorFlow version

TF2.12

### Custom code

No

### OS platform and distribution

Ubuntu 22.04

### Mobile device

_No response_

### Python version

3.10

### Bazel version

_No response_

### GCC/compiler version

_No response_

### CUDA/cuDNN version

CUDA 12, cuDNN 8

### GPU model and memory

_No response_

### Current behavior?

When profiling on GPU. Timestamp in Chrome trace format was incorrect due to shifting. The relevant commit is https://github.com/tensorflow/tensorflow/commit/701c1e97317ace357621b7f0bd4a2e427f16ed42#r144411330

There was a issue on  https://github.com/tensorflow/profiler/issues/238, but does not fix.

**Incorrect** timeline if `CollectData` was called:
https://github.com/tensorflow/tensorflow/blob/aeeeef0ba125dd2b28b59c5d144dd0a237a780c4/tensorflow/core/profiler/lib/device_profiler_session.h#L56-L59

**Correct** timelie if `CollectDataInternal` was called:
https://github.com/tensorflow/tensorflow/blob/a3e2c692c18649329c4210cf8df2487d2028e267/tensorflow/core/profiler/lib/device_profiler_session.h#L56-L59

The shifting was called in `PostProcessSingleHostXSpace` in `CollectData`
https://github.com/tensorflow/tensorflow/blob/aeeeef0ba125dd2b28b59c5d144dd0a237a780c4/third_party/xla/third_party/tsl/tsl/profiler/lib/profiler_session.cc#L81-L88
Is shifting expected behavior? If that, how to use the profiler session correctly?

### Standalone code to reproduce the issue

```shell
from absl import app
import logging

import tensorflow as tf
from tensorflow.python.client import timeline

tf.compat.v1.disable_eager_execution()

def test_profiler():
  shape = tf.constant([1000, 1000], dtype=tf.int64)
  x = tf.random.normal(shape)
  y = x ** 2
  z = y ** 2
  with tf.compat.v1.Session() as sess:
    run_options = tf.compat.v1.RunOptions(trace_level=tf.compat.v1.RunOptions.FULL_TRACE)
    run_metadata = tf.compat.v1.RunMetadata()
    #for i in range(3):
    sess.run(z, options=run_options, run_metadata=run_metadata)
    #logging.info("run_metadata.step_stats:%s", run_metadata.step_stats)
    tl = timeline.Timeline(run_metadata.step_stats)
    ctf = tl.generate_chrome_trace_format()
    with open('timeline.json', 'w') as f:
      f.write(ctf)

def main(argv):
  test_profiler()


if __name__ == "__main__":
  app.run(main)
```


### Relevant log output

_No response_
Repository: pytorch
Issue: The empty 1D or more D tensor for `median()/nanmedian()` with the deepest `dim` gets errors, not getting NaNs
Labels: module: error checking,triaged,actionable,module: empty tensor

### 🐛 Describe the bug

The empty 1D or more D tensor for [median()](https://pytorch.org/docs/stable/generated/torch.median.html) can get a NaN as shown below:

```python
import torch

my_tensor = torch.tensor([]) # 1D tensor

torch.median(input=my_tensor)
# tensor(nan)

my_tensor = torch.tensor([[]]) # 2D tensor

torch.median(input=my_tensor)
# tensor(nan)

my_tensor = torch.tensor([[[]]]) # 3D tensor

torch.median(input=my_tensor)
# tensor(nan)
```

But, the empty 1D or more D tensor for `median()` with the deepest `dim` gets the errors, not getting NaNs as shown below:

```python
import torch

my_tensor = torch.tensor([]) # 1D tensor

torch.median(input=my_tensor, dim=0) # Error

my_tensor = torch.tensor([[]]) # 2D tensor

torch.median(input=my_tensor, dim=1) # Error

my_tensor = torch.tensor([[[]]]) # 3D tensor

torch.median(input=my_tensor, dim=2) # Error
```

> IndexError: median(): Expected reduction dim 0 to have non-zero size.

> IndexError: median(): Expected reduction dim 1 to have non-zero size.

> IndexError: median(): Expected reduction dim 2 to have non-zero size.

### Versions

```python
import torch

torch.__version__ # 2.3.1+cu121
```

cc @malfet
Repository: ollama
Issue: (linux) snap support for linux installation this will solve many issues
Labels: feature request

This will give the app a snadboxed approach for installation and also it will give other security benifit
https://snapcraft.io/
 * Simplified installation:  They eliminate the need to manually resolve dependency issues, making software installation easier for users.
 * Isolation: They isolate applications from the system's core components and other applications, enhancing security and stability.
 * Faster updates: They enable faster and more frequent application updates without affecting the system.

Mainly updates will be pushed and app can be updated very easy.
Repository: ant-design
Issue: Upload defaultFileList should allow for fallback image in case of a broken Link.
Labels: 💡 Feature Request,Inactive

### What problem does this feature solve?

Problem: 

- I have an Upload component that has a defaultFileList of images.
- Some of the images have a broken link and the thumbnail being rendered is the default HTML broken image with the alt text. Not very visually pleasing. 
- I'd like to render a fallback image instead.
- I'm aware I can use renderItem to handle this but then I would be unable to use the default AntD component listing the files. I would have to create my own component.


### What does the proposed API look like?

```
<Upload
    defaultFileList={[
            {
              fallback: "public/images/fallback.svg",
              uid: "0",
              status: "done",
              name: "filename.svg",
              url: "https://***.com/images/filename.svg",
            },
          ]
    }                          
</Upload>

<!-- generated by ant-design-issue-helper. DO NOT REMOVE -->
Repository: ant-design
Issue: 在antd国内镜像官网首页点击中英文切换icon后，url路径会反复拼接删除index-cn，导致无法显示出页面
Labels: 📝 Documentation,Inactive

### Reproduction link

[https://ant-design.antgroup.com/index-cn?locale=zh-CN](https://ant-design.antgroup.com/index-cn?locale=zh-CN)

### Steps to reproduce

1.搜索点击antd官网
2.弹窗“国内用户推荐访问国内镜像以获得极速体验” 中点击立即前往
3.在https://ant-design.antgroup.com/index-cn?locale=zh-CN 页面，点击中英文切换icon
4.出现页面无法打开，url 一直反复切换为https://ant-design.antgroup.com/?locale=zh-CN和https://ant-design.antgroup.com/index-cn?locale=zh-CN

### What is expected?

正常打开页面，或者在还没有加语言切换功能的地方隐藏语言切换icon

### What is actually happening?

url反复变化，无法打开页面

| Environment | Info |
| --- | --- |
| antd | undefined |
| React | -- |
| System | Mac OS 14.1  |
| Browser | Chrome 126.0.0 |

---
在 https://ant.design/index-cn?locale=zh-CN 不会复现，如果在 https://ant.design/index-cn?locale=zh-CN 点击过切换中英文，再直接新开tab输入 https://ant-design.antgroup.com/index-cn?locale=zh-CN 也会出现url反复横跳现象

<!-- generated by ant-design-issue-helper. DO NOT REMOVE -->
Repository: godot
Issue: [AnimationTree Optimizer] .blend / .glb animation interpolation error
Labels: bug,topic:import,topic:animation

### Tested versions

Godot v4.2.2.stable.mono - Windows 10.0.22631 - Vulkan (Forward+) - dedicated NVIDIA GeForce RTX 3050 Laptop GPU (NVIDIA; 31.0.15.2698) - AMD Ryzen 7 5800U with Radeon Graphics (16 Threads)
Godot v4.3.beta3.mono - Windows 10.0.22631 - Vulkan (Forward+) - dedicated NVIDIA GeForce RTX 3050 Laptop GPU (NVIDIA; 31.0.15.2698) - AMD Ryzen 7 5800U with Radeon Graphics (16 Threads)

### System information

Windows 10.0.22631 - Vulkan (Forward+) - dedicated NVIDIA GeForce RTX 3050 Laptop GPU (NVIDIA; 31.0.15.2698) - AMD Ryzen 7 5800U with Radeon Graphics (16 Threads)

### Issue description

The animation imported in godot is not correct. 
I created a simple animation using cube in blender[v3.6 lts] and make interpolation of each frame be `Constant`. 
Then convert to .glb format. Import both .blend and .glb file into godot. 
> To import correctly, set FPS in godot to 15, same with blender. 

![image](https://github.com/user-attachments/assets/ac2a13ec-cee1-4795-95a3-d9a69055a07a)
> godot 4.2.2 linear, lost internal frames

![image](https://github.com/user-attachments/assets/00672869-c644-4b02-aff3-eaf789286eb0)
> godot 4.3-beta3 nearest, but lost internal frames

![image](https://github.com/user-attachments/assets/72539767-15ef-4efc-bea2-9ae51ed8abdd)
> blender

--- 
After having some test, i found that if the optimizer is turned off while importing, the `Constant` anim would be ok (tested in 4.3). 

![image](https://github.com/user-attachments/assets/25226835-9c28-4701-ba1d-95a57a78d3c8)
> Result. Godot 4.3-beta3, optimizer off

![image](https://github.com/user-attachments/assets/fa604993-f12a-417f-9ecf-08424513f8c0)
> Import Setting: optimizer off

![image](https://github.com/user-attachments/assets/c59506fb-ac60-44df-95a1-2d286c3c79f5)
> Import Settings: FPS set. 

### Steps to reproduce

See mrp. 

### Minimal reproduction project (MRP)

[anim_test.zip](https://github.com/user-attachments/files/16319270/anim_test.zip)
Repository: deno
Issue: deno cache --vendor does not let me choose a folder name
Labels: suggestion

Running `deno cache --vendor deps.ts` basically sets vendor to `true` and generates a "vendor" folder.

The problem is, that this "vendor" folder then sits in the middle of all my other source code folders, as I am not using a "src" folder or something like that.

It'd be nice to keep the functionality of `deno vendor --output=./_vendor`, where I can specify the target folder for vendoring into.

Example: `deno cache --vendor=./_vendor deps.ts`

This helps to keep things nice and tidy and also to keep my existing tooling, which I build up over the last 3 years of using Deno...

```sh
deno --version
deno 1.45.2 (release, x86_64-apple-darwin)
v8 12.7.224.12
typescript 5.5.2
```
Repository: ollama
Issue: Ability to pass --predict to llama.cpp server in ollama
Labels: feature request

Due to the structure of the deepseek v2 coder model, there was [a problem with gibberish when k shift occurred.](https://github.com/ggerganov/llama.cpp/issues/8498) 
And to solve this, [a patch](https://github.com/ggerganov/llama.cpp/pull/8501) that causes GGML_ASSERT when k shift occurs in the deepseek v2 model has been merged. 

Anyway, the easiest way to solve this problem is to pass the `--predict -2` option when running the llama.cpp server. This option limits the number of tokens to predict until the context is full.

It would be a good idea to set the n predict value as an environment variable when serving ollama, or set the value in the Modelfile so that it can be passed as the `--predict` value in `NewLlamaServer`.
Also, if possible, it would be good to apply it to ollama.com's Deepseek V2 models.

- Related issues
  - https://github.com/ollama/ollama/issues/5537
  - https://github.com/ollama/ollama/issues/5339
Repository: ui
Issue: [bug]: Checkbox unintentional movement
Labels: bug

### Describe the bug

If you want to use the checkbox component alone, (without div and label) probably u don't want a div as father, and without that div with flex class when u click on the checkbox it moves to up and down.

To fix that u only need put 'flex' class on the CheckboxPrimitive.Root component

### Affected component/components

Checkbox

### How to reproduce

Using the component like that:

<div>
    <Checkbox id="terms" />
    <label
        htmlFor="terms"
        className="text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"
    >
        Accept terms and conditions
    </label>
</div>

export default CheckboxDemo;

### How to fix

const Checkbox = React.forwardRef<
  React.ElementRef<typeof CheckboxPrimitive.Root>,
  React.ComponentPropsWithoutRef<typeof CheckboxPrimitive.Root>
>(({ className, ...props }, ref) => (
  <CheckboxPrimitive.Root
    ref={ref}
    className={cn(
      "peer h-4 w-4 shrink-0 rounded-sm border border-primary ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground **flex**",
      className
    )}
    {...props}
  >
    <CheckboxPrimitive.Indicator
      className={cn("flex items-center justify-center text-current")}
    >
      <Check className="h-4 w-4" />
    </CheckboxPrimitive.Indicator>
  </CheckboxPrimitive.Root>
))
Checkbox.displayName = CheckboxPrimitive.Root.displayName

### System Info

```bash
Windows, Firefox / Chrome
```

### Before submitting

- [X] I've made research efforts and searched the documentation
- [X] I've searched for existing issues
Repository: ollama
Issue: List command optional flag  to display license
Labels: feature request

It could be useful, in corporate environment, for security and compliance, to be able to display with list command, using an optional flag, also type of license, for example:

ollama list -l

display usual information, but also related license name for each model
Repository: PowerToys
Issue: PowerToys - FancyZones will not allow changing layout, making a new layout or edit a layout, all permission errors.
Labels: Issue-Bug,Product-FancyZones,Needs-Triage

### Microsoft PowerToys version

0.82.1

### Installation method

GitHub

### Running as admin

No

### Area(s) with issue?

FancyZones

### Steps to reproduce

I cant edit, or save fancyzones at all, ive tried uninstalling and re-installing, running as admin and not admin.
```
---------------------------
FancyZones Editor Exception Handler
---------------------------
Please report the bug to https://aka.ms/powerToysReportBug 
Error applying layout: Access to the path 'C:\Users\Tom\AppData\Local\Microsoft\PowerToys\FancyZones\custom-layouts.json' is denied.
---------------------------
OK   
---------------------------
```


![image](https://github.com/user-attachments/assets/2d4b6e7c-4123-4ff5-943c-e67408f85a2a)




### ✔️ Expected Behavior

To be able to edit custom zones

### ❌ Actual Behavior

Will not save

### Other Software

_No response_
Repository: ant-design
Issue: Typography components using the `ellipsis` property with `onEllipsis` callback always displays ellipsis
Labels: Inactive,improvement

### Reproduction link

[![Edit on StackBlitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/edit/react-ancyys?file=demo.tsx)

### Steps to reproduce

Utilize the Typography Title component, incorporating an ellipsis property with an onEllipsis callback. Note that the standard three dots used for text overflow may persist even when the typography has sufficient space.

### What is expected?

The Typography component should not display ellipsis if it has sufficient space.

### What is actually happening?

The Typography component consistently displays ellipsis.

| Environment | Info |
| --- | --- |
| antd | 5.19.3 |
| React | react |
| System | Microsoft Windows 10 Pro |
| Browser | Chrome v126.0.6478.127 |

<!-- generated by ant-design-issue-helper. DO NOT REMOVE -->