sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: bitcoin
Issue: Prioritize processing of peers based on their CPU usage
Labels: Feature,Brainstorming

### Please describe the feature you'd like to see added.

Currently, we process messages to/from all peers in a loop where every peer is processed once (has the same weight). The list of peers is shuffled before every loop.

Considering a scenario where we spend considerably more CPU time for some peers compared to others, does it make sense to de-prioritize CPU-hungry peers? This might be happening deliberately (a CPU DoS attack) or not.

For example: if we spent 5 CPU seconds to process each one of the peers `Bad` and `Demanding` and 1 CPU second to process peers `Normal` and `Light`. Then on the next loop, we can process just `Normal` and `Light` so they now account to 2 CPU seconds each and skip `Bad` and `Demanding`. Do a few loops like this until everybody is around 5 CPU seconds and then process all of them again.

I am not sure how much sense this makes, but at least it seems worthy of brainstorming.

### Is your feature related to a problem, if so please describe it.

https://github.com/bitcoin/bitcoin/pull/30572 aims to address a problem of peers sending a lot of costly-to-validate-but-invalid transactions in an attempt to CPU DoS a node. To me it seems that whether those transactions are requested by the victim or are sent unsolicited is secondary. More importantly, willingly or not, some peers are eating the CPU and some not, so this is a broader issue.

### Describe the solution you'd like

Aim to spend approximately the same amount of CPU time for every peer. Or, within some reasonable margin, e.g. if the difference between the lightest and the heaviest peer is more than 10x, then trigger some protective mechanism.

### Describe any alternatives you've considered

Drop unsolicited transactions. IMO that would not really resolve the DoS.

### Please leave any additional context

I got this idea while reading https://delvingbitcoin.org/t/cpu-usage-of-peers/196/2
Repository: next.js
Issue: headers function get method only return full referrer url on page refresh and not on page visited through Link component.
Labels: bug,Navigation

### Link to the code that reproduces this issue

https://github.com/Rajesh-Poojari-Dmart/nextIssue

### To Reproduce

## Step 1

Add the following `generateMetadata` function in a couple of dynamic page files that are linked to each other using the Link component:

```javascript
export async function generateMetadata() {
   const headersList = headers();
   const refererUrl = headersList.get("referer") || null;
  
   return {
      openGraph: {
         url: refererUrl
      },
      alternates: {
         canonical: refererUrl,
      },
   };
}
```

## Step 2

Suppose you visit from Homepage "/" to some dynamic url "/products/{productName}" using Link component, the above genareteMetadata function adds opengraph and canonical url as "http:localhost:3000/" in head tag of /product/{productName} page, but when I refresh the page /product/{productName} , genareteMetadata function adds "http:localhost:3000/product/{productName}" in opengraph and canonical url.


### Current vs. Expected behavior

### Current behaviour
The headers function get method does not get the full url inside generateMetadata on page visited through Link component.

### Expected behaviour
The headers function should get the full url inside generateMetadata on page visited through Link component.

### Provide environment information

```bash
Operating System:
  Platform: darwin
  Arch: arm64
  Version: Darwin Kernel Version 21.6.0: Mon Dec 19 20:46:01 PST 2022; root:xnu-8020.240.18~2/RELEASE_ARM64_T8101
  Available memory (MB): 8192
  Available CPU cores: 8
Binaries:
  Node: 20.9.0
  npm: 10.1.0
  Yarn: 1.22.21
  pnpm: N/A
Relevant Packages:
  next: 14.2.14 // Latest available version is detected (14.2.14).
  eslint-config-next: 14.2.14
  react: 18.3.1
  react-dom: 18.3.1
  typescript: 5.6.2
Next.js Config:
  output: N/A
```


### Which area(s) are affected? (Select all that apply)

Navigation

### Which stage(s) are affected? (Select all that apply)

next dev (local)

### Additional context

_No response_
Repository: PowerToys
Issue: Keyboard stops working on remote machine.  Mouse continues to work.
Labels: Issue-Bug,Needs-Triage

### Microsoft PowerToys version

0.85.0

### Installation method

PowerToys auto-update

### Running as admin

No

### Area(s) with issue?

Mouse Without Borders

### Steps to reproduce

When trying to control the mouse and keyboard on my remote laptop, the mouse will work but not the keyboard.  Happens when I am just starting to use it for the day.

### ✔️ Expected Behavior

Keyboard and mouse should work on the remote laptop.

### ❌ Actual Behavior

Only the mouse works but not the keyboard.

### Other Software

_No response_
Repository: excalidraw
Issue: Paste Event doesn't get invoked within Shadow Root
Labels: bug

Thank you for your work.

The issue I'm seeing is that the paste event doesn't get recognized when I use excalidraw within a shadow root. There is probably an easy fix: I assume if the event target here would be set to the correct shadow root, everything would work well: https://github.com/excalidraw/excalidraw/blob/47ee8a00945793340bb20715b2f383a4c3da2139/packages/excalidraw/components/App.tsx#L2599

Here's a minimal repro: https://codesandbox.io/p/sandbox/empty-violet-68d58w?workspaceId=01e8ba10-da5e-408e-b38e-262278fa125d
(you'll have to use the browser dev tools because codesandbox doesn't show shadow roots in their embedded dev tools)

I'm happy to contribute a fix if you tell me to go ahead with it. Shadow root support has to be "hacked in" because styles are attached globally. What's the current strategy on this? Have you guys talked / decided on a strategy concerning general shadow root support? Will it help if I propose a fix?

Best Regards!
Repository: transformers
Issue: DataCollatorWithFlattening is incompatible with non - list input ids
Labels: Feature request,bug,HACKTOBERFEST-ACCEPTED

### System Info

latest transformers

### Who can help?

@ArthurZucker 

### Information

- [ ] The official example scripts
- [x] My own modified scripts

### Tasks

- [ ] An officially supported task in the `examples` folder (such as GLUE/SQuAD, ...)
- [x] My own task or dataset (give details below)

### Reproduction

```python
from transformers import GPT2Tokenizer
tokenizer = GPT2Tokenizer.from_pretrained("openai-community/gpt2")
example = tokenizer("A test sentence", return_tensors="pt")
example = {k: v.flatten() for k, v in tensor_example.items()}
collator([example]*2)
```

### Expected behavior

Collator should work with all output types supported by tokenizer.
Repository: flutter
Issue: iOS: Ensure all delegates use weak pointers and eliminate manual nilling of pointers in [FlutterEngine/FlutterViewController dealloc]
Labels: engine,P2,c: tech-debt,team-ios,triaged-ios

Followup to migrating all iOS translation units to compilation with ARC.

https://github.com/flutter/engine/blob/205484009711c2f0d85a4c45666d187184493b41/shell/platform/darwin/ios/framework/Source/FlutterEngine.mm#L299-L321

and

https://github.com/flutter/engine/blob/d38f5e560a98f491fb1b3e24e19cc78d2b110b99/shell/platform/darwin/ios/framework/Source/FlutterViewController.mm#L979-L988
Repository: TypeScript
Issue: `asserts this is T` does not narrow type of `this`
Labels: Cursed?,Possible Improvement

### 🔎 Search Terms

- `asserts this is T`
- `narrow`
- `assertions`
- I also checked #59707, but it is unrelated (generic types).


### 🕗 Version & Regression Information

- Playground: `v5.7.0-dev.20241004`
- At least since `v5.6.2`

### ⏯ Playground Link

https://www.typescriptlang.org/play/?#code/MYGwhgzhAECC0G8BQ1oHsB2ICeARApgGYCWG+AJgJIawAUAlIiqtMJhGiPgHQhoDmtAESwh9ANzMAvkmaQI+AE4AXOvQBc0eUuUxlAC2IwjcRNBkzZoedABCTVNpVrNT3dAMmT8BOaSXlbAAHfGgAYWgAXlMAHztJJEIAVwxgZWJMLSgdOmBNMI0shRUYYGhvJktk1PTM5XwIZQBGWjzwxmRUYG43NUku7kwcAhIyKhoGcWgAemnoAFFFRTRFTQAFZZCVbGgAciG8IlIKalhd6HI0BugMNGVofAAPI3u64NDdsN3uaA20LcCewOI2O4zOFyuMFu9yeL3QGA87z2tm+-lk1TSGQR9UaACZWvkOnJss5WhJmN1gUcxqdJjM5gB1FYAawgAEI0dAgA

### 💻 Code

```ts repro
class A {
  onlyDefinedInA() {
    console.log("A");
  }

  assertA(): asserts this is A { }
}


class B {
  assertA(): asserts this is A { }
}

type C = A | B;

function assertA(c: C): asserts c is A {
}

function test1(c: C) {
  c.assertA();
  c.onlyDefinedInA(); // Error: Property 'onlyDefinedInA' does not exist on type 'C'. Property 'onlyDefinedInA' does not exist on type 'B'.
}

function test2(c: C) {
  assertA(c);
  c.onlyDefinedInA(); // Works!
}

```

[Workbench Repro](https://www.typescriptlang.org/dev/bug-workbench/?#code/MYGwhgzhAECC0G8BQ1oHsB2ICeARApgGYCWG+AJgJIawAUAlIiqtMJhGiPgHQhoDmtAESwh9ANzMAvkmaQI+AE4AXOvQBc0eUuUxlAC2IwjcRNBkzZoedABCTVNpVrNT3dAMmT8BOaSXlbAAHfGgAYWgAXlMAHztJJEIAVwxgZWJMLSgdOmBNMI0shRUYYGhvJktk1PTM5XwIZQBGWjzwxmRUYG43NUku7kwcAhIyKhoGcWgAemnoAFFFRTRFTQAFZZCVbGgAciG8IlIKalhd6HI0BugMNGVofAAPI3u64NDdsN3uaA20LcCewOI2O4zOFyuMFu9yeL3QGA87z2tm+-lk1TSGQR9UaACZWvkOnJss5WhJmN1gUcxqdJjM5gB1FYAawgAEI0UA)

### 🙁 Actual behavior

Type of `c` is not narrowed after the method call, producing an error.

### 🙂 Expected behavior

I expect the member function to to perform type narrowing.

### Additional information about the issue

_No response_
Repository: transformers
Issue: Centralized Page for Domain Whitelisting (Hugging Face Models)
Labels: Feature request

### Feature request

Is it possible to create a dedicated page that lists all the domains where Hugging Face models, such as those stored on cdn-lfs.hf.co, are hosted? This page would serve as a reference for users working in corporate environments, where whitelisting of individual domains is required.

### Motivation

Many organizations, particularly those behind corporate networks, require that domains be whitelisted individually for security and access reasons. For users working in such environments, identifying and manually whitelisting the necessary domains for model access can be a cumbersome process. A centralized list of the domains Hugging Face uses to host and serve models would significantly streamline this process, ensuring seamless access to models across corporate networks without delays or security issues.
Repository: angular
Issue: Certain hierarchies of animated components don't work
Labels: area: animations

### Which @angular/* package(s) are the source of the bug?

animations

### Is this a regression?

No

### Description

I have **MainComponent**, inside of it there are tabs (**Content1** and **Content2** components) represented via `@switch` statement.
Based on `activeTab` I render one of them.

**MainСomponent** is animated when opened/closed, so it has
```
host: { '[@mainComponentAnimation]': '' },
animations: [mainComponentAnimations]
```
`mainComponentAnimations` also contains animations for switching the tabs - `@contentAnimations`. These are used like this:
```
@switch (activeTab) {
  @case (1) {
    <app-content1 @contentAnimation></app-content1>
  }

  @case (2) {
    <app-content2 @contentAnimation></app-content2>
  }
}
```

**Content2** has its own content animations, so it has `animations: [...] too`.

**THE ISSUE:**
`:leave` animation of **Content2** (from `@contentAnimation`) is broken when both of these defined:
1. `host: { '[@mainComponentAnimation]': '' }` in **MainComponent**.
2. `animations: [...]` in **Content2**.

Meaning if you comment out any of those, it works fine.

Play around with the reproduction and see for yourself.

### Please provide a link to a minimal reproduction of the bug

https://stackblitz.com/edit/stackblitz-starters-hyvqbj

### Please provide the exception or error you saw

_No response_

### Please provide the environment you discovered this bug in (run `ng version`)

Angular CLI: 18.2.5
Node: 20.11.1
Package Manager: yarn 1.22.19
OS: win32 x64

Angular: 18.2.5
... animations, cdk, cli, common, compiler, compiler-cli, core
... forms, language-service, material, material-moment-adapter
... platform-browser, platform-browser-dynamic, platform-server
... router, service-worker

Package                         Version
---------------------------------------------------------
@angular-devkit/architect       0.1802.5
@angular-devkit/build-angular   18.2.5
@angular-devkit/core            18.2.5
@angular-devkit/schematics      18.2.5
@angular/fire                   18.0.1
@schematics/angular             18.2.5
rxjs                            7.8.1
typescript                      5.5.4
webpack                         5.94.0
zone.js                         0.15.0

### Anything else?

_No response_
Repository: godot
Issue: rigged models display strange scale and lose sync with skeletons when switching tabs
Labels: bug,topic:3d

### Tested versions

4.4 dev3

### System information

Godot v4.4.dev3 - Windows 10.0.22631 - Multi-window, 1 monitor - Vulkan (Forward+) - dedicated NVIDIA GeForce RTX 4060 (NVIDIA; 32.0.15.6094) - 12th Gen Intel(R) Core(TM) i5-12400F (12 threads)

### Issue description

rigged meshes with a skeleton change to an odd scale and display odd syncing with skeletons when changing tabs in the editor. this is fixed when reloading the scene but appears to be a new issue with 4.4

### Steps to reproduce

set a rigged model (possibly requires an animation player) to editable children, switch scenes in editor.

### Minimal reproduction project (MRP)

![image](https://github.com/user-attachments/assets/74bf9d0e-ea17-4a0e-ac88-ec38be685866)
Repository: godot
Issue: Compilation failure with `lto=full` on Windows with MSVC `cl.exe`: LNK1248: image size exceeds maximum allowable size (FFFFFFFF)
Labels: bug,platform:windows,topic:buildsystem,confirmed,regression

### Tested versions

master f032af74536b317b23c7fca3bc7318ced5537344

### System information

Windows 11 - Intel i5 9600k

### Issue description

Compilation randomy fails after a while:
```
[...}
Compiling scene\gui\box_container.cpp ...
Compiling scene\gui\button.cpp ...
Compiling scene\gui\center_container.cpp ...
Compiling scene\gui\check_box.cpp ...
editor\editor.windows.editor.x86_64.lib : fatal error LNK1248: image size (100764120) exceeds maximum allowable size (FFFFFFFF)
Compiling scene\gui\check_button.cpp ...
Compiling scene\gui\code_edit.cpp ...
Compiling scene\gui\color_mode.cpp ...
Compiling scene\gui\color_picker.cpp ...
Compiling scene\gui\color_rect.cpp ...
Compiling scene\gui\container.cpp ...
scons: *** [editor\editor.windows.editor.x86_64.lib] Error 1248
scons: building terminated because of errors.
[Time elapsed: 00:08:12.40]
```

### Steps to reproduce

clone godot
`scons p=windows arch=x86_64 production=yes lto=full target=editor optimize=speed deprecated=no`


### Minimal reproduction project (MRP)

-
Repository: PowerToys
Issue: More comfortable window resizing functionality
Labels: Needs-Triage

### Description of the new feature / enhancement

It would be nice to have some feature(s) of NiftyWindows, which isn't further maintained since several years.
E.g. (Extract from NiftyWindows help (https://ahkscript.github.io/NiftyWindows/features/)):

   * **/RIGHT_BUTTON+DRAG/**
      This is the most powerful feature of NiftyWindows. The area of
      every window is tiled in a virtual 9-cell grid with three columns
      and rows. The center cell is the largest one and you can grab and
      move a window around by clicking and holding it with the right
      mouse button. **The other eight corner cells are used to resize a
      resizable window in the same manner.**

      Note: This drag and resize feature is not provided on some certain
      windows because this mouse behaviour may have a special handling
      controlled by the application itself. You can use the forced mode
      (see explanation in the introduction of 'features') to manipulate
      these windows as well. Currently the following windows (and its
      possible child windows) have been taken into account: ...


### Scenario when this would be used?

It is more comfortable to resize e.g. an editor-window, because the mouse doesn't need to be placed on exactly on the borders of the window. Instead the mouse just needs to be positioned e.g. in the first 1/3 area pane of the window, which is much larger, than the small border of the window.

### Supporting information

Because NiftyWindows was rather cool, e.g. autohotkey tries also to emulate the functionality of NiftyWindows:
https://www.autohotkey.com/board/topic/2460-niftywindows/
Repository: transformers
Issue: Request for Iterative Generation in Pipeline (e.g., LLaMA model)
Labels: Feature request

### Feature request

I would like to ask if there is a way to perform iterative generation (n times) within the pipeline, specifically for models like LLMs. If this feature is not available, is there any plan to implement it in the future?

Example:
```python
pipeline = transformers.pipeline(
            "text-generation",
            model="meta-llama/Llama-3.1-8B-Instruct",
            model_kwargs={"torch_dtype": torch.bfloat16},
            device_map="auto",
        ) 

# Generate once
outputs = llama_client(
              messages,
              max_new_tokens=max_tokens
          )
# Generate n times
outputs = llama_client(
              messages,
              max_new_tokens=max_tokens,
              n = n
          )
```

Similar GPT API
```python
response = client.chat.completions.create(
            model=model,
            messages=messages, 
            max_tokens=max_tokens,
            temperature=temperature, 
            n=n,  
        )
```

I am also aware that iterative generation can be done using a for loop, but I am wondering if there is a more efficient or optimized way to generate multiple iterations (n times) within the pipeline for models.

https://community.openai.com/t/how-does-n-parameter-work-in-chat-completions/288725


### Motivation

build connection between LLM api and transformer pipeline

### Your contribution

Request
Repository: ollama
Issue: VideoCore GPU support
Labels: feature request

Required to be able to run models on RaspberryPi's GPU.
Repository: rust
Issue: Tracking issue for release notes of #111645: Tracking Issue for `UnsafeCell::from_mut`
Labels: T-libs-api,relnotes,relnotes-tracking-issue


This issue tracks the release notes text for #111645.

### Steps

- [ ] Proposed text is drafted by PR author (or team) making the noteworthy change.
- [ ] Issue is nominated for release team review of clarity for wider audience.
- [ ] Release team includes text in release notes/blog posts.

### Release notes text

The responsible team for the underlying change should edit this section to replace the automatically generated link with a succinct description of what changed, drawing upon text proposed by the author (either in discussion or through direct editing).

```markdown
# Category (e.g. Language, Compiler, Libraries, Compatibility notes, ...)
- [Tracking Issue for `UnsafeCell::from_mut`](https://github.com/rust-lang/rust/issues/111645)
```

> [!TIP]
> Use the [previous releases](https://doc.rust-lang.org/nightly/releases.html) categories to help choose which one(s) to use.
> The category will be de-duplicated with all the other ones by the release team.
>
> *More than one section can be included if needed.*

### Release blog section

If the change is notable enough for inclusion in the blog post, the responsible team should add content to this section.
*Otherwise leave it empty.*

```markdown
```

cc @JoJoJet -- origin issue/PR authors and assignees for starting to draft text
Repository: rust
Issue: Tracking issue for release notes of #111735: Tracking Issue for `BufRead::skip_until`
Labels: T-libs-api,relnotes,relnotes-tracking-issue


This issue tracks the release notes text for #111735.

### Steps

- [ ] Proposed text is drafted by PR author (or team) making the noteworthy change.
- [ ] Issue is nominated for release team review of clarity for wider audience.
- [ ] Release team includes text in release notes/blog posts.

### Release notes text

The responsible team for the underlying change should edit this section to replace the automatically generated link with a succinct description of what changed, drawing upon text proposed by the author (either in discussion or through direct editing).

```markdown
# Category (e.g. Language, Compiler, Libraries, Compatibility notes, ...)
- [Tracking Issue for `BufRead::skip_until`](https://github.com/rust-lang/rust/issues/111735)
```

> [!TIP]
> Use the [previous releases](https://doc.rust-lang.org/nightly/releases.html) categories to help choose which one(s) to use.
> The category will be de-duplicated with all the other ones by the release team.
>
> *More than one section can be included if needed.*

### Release blog section

If the change is notable enough for inclusion in the blog post, the responsible team should add content to this section.
*Otherwise leave it empty.*

```markdown
```

cc @WilliamVenner -- origin issue/PR authors and assignees for starting to draft text
Repository: go
Issue: x/pkgsite: support markdown alerts in readme
Labels: FeatureRequest,pkgsite

### What is the URL of the page with the issue?

https://pkg.go.dev/github.com/docker/buildx#section-readme

### What is your user agent?

All user agents

> [!NOTE]
> - This issue affects all web browsers.
> - GitHub introduced markdown alerts [in 2023](https://github.blog/changelog/2023-12-14-new-markdown-extension-alerts-provide-distinctive-styling-for-significant-content/) as an extension to [GfM](https://github.github.com/gfm/) (2019).


### Screenshot

Got unformatted alerts (e.g. `[!WARNING]`) at https://pkg.go.dev/github.com/docker/buildx#section-readme:

![image](https://github.com/user-attachments/assets/3b866d77-52be-4936-8944-5a61d9d710fe)

Got formatted alerts on GitHub at https://github.com/docker/buildx:

![image](https://github.com/user-attachments/assets/fda30a4f-b6ab-4e72-bfc1-7a68739acbe8)

### What did you do?

View projects using markdown alerts like github.com/docker/buildx on pkg.go.dev.

Or use any of these GitHub markdown alerts in a README.md.

```
> [!NOTE]
> Useful information that users should know, even when skimming content.

> [!TIP]
> Helpful advice for doing things better or more easily.

> [!IMPORTANT]
> Key information users need to know to achieve their goal.

> [!WARNING]
> Urgent info that needs immediate user attention to avoid problems.

> [!CAUTION]
> Advises about risks or negative outcomes of certain actions.
```


### What did you see happen?

Markdown alerts are not formatted as alerts at pkg.go.dev.

For example, `[!WARNING]`, `[!IMPORTANT]`, and `[!NOTE]` alerts are not formatted as alerts.


### What did you expect to see?

Expected to see markdown alerts formatted as alerts.  [GitHub documentation](https://docs.github.com/en/get-started/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax#alerts) lists these alerts:

> [!NOTE]
> Useful information that users should know, even when skimming content.

> [!TIP]
> Helpful advice for doing things better or more easily.

> [!IMPORTANT]
> Key information users need to know to achieve their goal.

> [!WARNING]
> Urgent info that needs immediate user attention to avoid problems.

> [!CAUTION]
> Advises about risks or negative outcomes of certain actions.

EDIT: Added note that GitHub introduced markdown alerts [in 2023](https://github.blog/changelog/2023-12-14-new-markdown-extension-alerts-provide-distinctive-styling-for-significant-content/) as an extension to [GfM](https://github.github.com/gfm/) (2019). Also clarified and reordered screenshots.