helloadhavan/github_issues huggingface dataset:
Repository: electron/electron
Pull request: fix:  Windows: Calling window.setFocusable(true) will no longer cause a window to lose focus

Backport of #45640

See that PR for details.


Notes: Windows: Calling window.setFocusable(true) will no longer cause a window to lose focus

Changed files:
filename: shell/browser/native_window_views.cc
patch: @@ -1364,7 +1364,8 @@ void NativeWindowViews::SetFocusable(bool focusable) {
     ex_style |= WS_EX_NOACTIVATE;
   ::SetWindowLong(GetAcceleratedWidget(), GWL_EXSTYLE, ex_style);
   SetSkipTaskbar(!focusable);
-  Focus(false);
+  if (!focusable)
+    Focus(false);
 #endif
 }
Repository: facebook/react
Pull request: [ci] Use correct revision for Meta builds


There was a bug previously in our commit artifacts step where the emitted REVISION hash would reference the commit on the builds branch rather than from `main`.

Given that our internal manual sync script also does this, let's align them both to always reference the commit from `main` instead.
---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed with [ReviewStack](https://reviewstack.dev/facebook/react/pull/32680).
* __->__ #32680
* #32679
* #32678

Changed files:
filename: .github/workflows/runtime_commit_artifacts.yml
patch: @@ -151,9 +151,9 @@ jobs:
           ls -R ./compiled-rn
       - name: Add REVISION files
         run: |
-          echo ${{ github.sha }} >> ./compiled/facebook-www/REVISION
+          echo ${{ inputs.commit_sha || github.event.workflow_run.head_sha || github.sha }} >> ./compiled/facebook-www/REVISION
           cp ./compiled/facebook-www/REVISION ./compiled/facebook-www/REVISION_TRANSFORMS
-          echo ${{ github.sha}} >> ./compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/REVISION
+          echo ${{ inputs.commit_sha || github.event.workflow_run.head_sha || github.sha }} >> ./compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/REVISION
       - name: "Get current version string"
         id: get_current_version
         run: |
Repository: facebook/react
Pull request: [ci] Cache playwright browsers


No reason to download them from scratch every time.
---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed with [ReviewStack](https://reviewstack.dev/facebook/react/pull/32678).
* #32680
* #32679
* __->__ #32678

Changed files:
filename: .github/workflows/runtime_build_and_test.yml
patch: @@ -566,6 +566,24 @@ jobs:
         run: rm -rf build
       - run: yarn install --frozen-lockfile
         if: steps.node_modules.outputs.cache-hit != 'true'
+      - run: yarn --cwd fixtures/flight install --frozen-lockfile
+        if: steps.node_modules.outputs.cache-hit != 'true'
+      - name: Store Playwright version
+        id: playwright_version
+        run: |
+          PLAYWRIGHT_VERSION=$(npm ls @playwright/test | grep @playwright | sed 's/.*@//')
+          echo "Playwright's Version: $PLAYWRIGHT_VERSION"
+          echo "playwright_version=$PLAYWRIGHT_VERSION" >> "$GITHUB_OUTPUT"
+      - name: Cache Playwright Browsers for Playwright's Version
+        id: cache_playwright_browsers
+        uses: actions/cache@v4
+        with:
+          path: ~/.cache/ms-playwright
+          key: playwright-browsers-v6-${{ runner.arch }}-${{ runner.os }}-${{ steps.playwright_version.outputs.playwright_version }}
+      - name: Playwright install deps
+        if: steps.cache_playwright_browsers.outputs.cache-hit != 'true'
+        working-directory: fixtures/flight
+        run: npx playwright install --with-deps chromium
       - name: Restore archived build
         uses: actions/download-artifact@v4
         with:
@@ -574,16 +592,6 @@ jobs:
           merge-multiple: true
       - name: Display structure of build
         run: ls -R build
-      - name: Install fixture dependencies
-        working-directory: fixtures/flight
-        run: |
-          yarn install --frozen-lockfile --cache-folder ~/.cache/yarn
-          if [ $? -ne 0 ]; then
-            yarn install --frozen-lockfile --cache-folder ~/.cache/yarn
-          fi
-      - name: Playwright install deps
-        working-directory: fixtures/flight
-        run: npx playwright install --with-deps chromium
       - name: Run tests
         working-directory: fixtures/flight
         run: yarn test
Repository: vercel/next.js
Pull request: [ci] Bump Lerna to 5.x

I want to get rid of the incredibly slow `git remote update` Lerna is doing. No point patching/filing issues against super old releases so I'll first bump it incrementally to 9.x and then check again if it's still slow.

[v5 release notes](https://github.com/lerna/lerna/releases/tag/v5.0.0). No apparent breakage that we need to address stands out.


## Test plan

- Will trigger canary release once that's merged

Changed files:
filename: bench/fuzzponent/package.json
patch: @@ -1,5 +1,6 @@
 {
   "name": "fuzzponent",
+  "version": "0.0.1",
   "bin": {
     "fuzzponent": "./bin/fuzzponent.js"
   },

filename: bench/next-minimal-server/package.json
patch: @@ -1,5 +1,6 @@
 {
   "name": "next-minimal-server",
+  "version": "0.0.1",
   "description": "Minimal server for Next.js for benchmarking/perf analysis purposes.",
   "bin": "./bin/minimal-server.js",
   "peerDependencies": {

filename: package.json
patch: @@ -230,7 +230,7 @@
     "kleur": "^4.1.0",
     "ky": "0.19.1",
     "ky-universal": "0.6.0",
-    "lerna": "4.0.0",
+    "lerna": "5.6.2",
     "lint-staged": "15.2.2",
     "lodash": "4.17.20",
     "lost": "8.3.1",
Repository: facebook/react
Pull request: [ci] Parameterize branch cleanup


Allow a PR number to be passed as input


Changed files:
filename: .github/workflows/shared_cleanup_branch_caches.yml
patch: @@ -6,6 +6,10 @@ on:
     types:
       - closed
   workflow_dispatch:
+    inputs:
+      pr_number:
+        required: true
+        type: string
 
 jobs:
   cleanup:
@@ -23,13 +27,13 @@ jobs:
 
           ## Setting this to not fail the workflow while deleting cache keys.
           set +e
-          echo "Deleting caches..."
           for cacheKey in $cacheKeysForPR
           do
               gh cache delete $cacheKey
+              echo "Deleting $cacheKey"
           done
           echo "Done"
         env:
           GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
           GH_REPO: ${{ github.repository }}
-          BRANCH: refs/pull/${{ github.event.pull_request.number }}/merge
+          BRANCH: refs/pull/${{ inputs.pr_number || github.event.pull_request.number }}/merge
Repository: ollama/ollama
Pull request: cmd: preserve exact bytes when displaying template/system layers

Stop corrupting the output of template and system layers with extraneous newlines, which can alter model behavior if the output is used as input to a new model.

Changed files:
filename: cmd/cmd.go
patch: @@ -800,9 +800,9 @@ func ShowHandler(cmd *cobra.Command, args []string) error {
 		case "parameters":
 			fmt.Println(resp.Parameters)
 		case "system":
-			fmt.Println(resp.System)
+			fmt.Print(resp.System)
 		case "template":
-			fmt.Println(resp.Template)
+			fmt.Print(resp.Template)
 		}
 
 		return nil
Repository: ggml-org/llama.cpp
Pull request: ggml: ggml-cpu: force-no-lto-for-cpu-feats

When LTO enabled in build environments it forces all builds to have LTO in place. But feature detection logic is fragile, and causing Illegal instruction errors with lto. This disables LTO for the feature detection code to prevent cross-module optimization from inlining architecture-specific instructions into the score function. Without this, LTO can cause SIGILL when loading backends on older CPUs (e.g., loading power10 backend on power9 crashes before feature check runs).

Please also see https://salsa.debian.org/deeplearning-team/ggml/-/merge_requests/6 for more information about the issue we saw on ppc64el builds with LTO enabled in ubuntu.

*Make sure to read the [contributing guidelines](https://github.com/ggml-org/llama.cpp/blob/master/CONTRIBUTING.md) before submitting a PR*


Changed files:
filename: ggml/src/ggml-cpu/CMakeLists.txt
patch: @@ -9,6 +9,11 @@ function(ggml_add_cpu_backend_features cpu_name arch)
     target_compile_definitions(${GGML_CPU_FEATS_NAME} PRIVATE ${ARGN})
     target_compile_definitions(${GGML_CPU_FEATS_NAME} PRIVATE GGML_BACKEND_DL GGML_BACKEND_BUILD GGML_BACKEND_SHARED)
     set_target_properties(${GGML_CPU_FEATS_NAME} PROPERTIES POSITION_INDEPENDENT_CODE ON)
+    # Disable LTO for the feature detection code to prevent cross-module optimization
+    # from inlining architecture-specific instructions into the score function.
+    # Without this, LTO can cause SIGILL when loading backends on older CPUs
+    # (e.g., loading power10 backend on power9 crashes before feature check runs).
+    target_compile_options(${GGML_CPU_FEATS_NAME} PRIVATE -fno-lto)
     target_link_libraries(${cpu_name} PRIVATE ${GGML_CPU_FEATS_NAME})
 endfunction()
Repository: vuejs/vue
Pull request: remove unnecessary codes

Combining switch cases.

<!--
Please make sure to read the Pull Request Guidelines:
https://github.com/vuejs/vue/blob/dev/.github/CONTRIBUTING.md#pull-request-guidelines
-->

<!-- PULL REQUEST TEMPLATE -->
<!-- (Update "[ ]" to "[x]" to check a box) -->

**What kind of change does this PR introduce?** (check at least one)

- [ ] Bugfix
- [ ] Feature
- [ ] Code style update
- [x] Refactor
- [ ] Build-related changes
- [ ] Other, please describe:

**Does this PR introduce a breaking change?** (check one)

- [ ] Yes
- [x] No




Changed files:
filename: src/core/observer/array.js
patch: @@ -29,8 +29,6 @@ export const arrayMethods = Object.create(arrayProto)
     let inserted
     switch (method) {
       case 'push':
-        inserted = args
-        break
       case 'unshift':
         inserted = args
         break
Repository: vercel/next.js
Pull request: [turbopack[ Use a frozenset in ImportUsage

This set is only ever iterated so this just saves memory.


Changed files:
filename: turbopack/crates/turbopack-core/src/resolve/mod.rs
patch: @@ -7,15 +7,14 @@ use std::{
 };
 
 use anyhow::{Result, bail};
-use auto_hash_map::AutoSet;
 use bincode::{Decode, Encode};
 use either::Either;
 use once_cell::sync::Lazy;
 use rustc_hash::{FxHashMap, FxHashSet};
 use serde::{Deserialize, Serialize};
 use smallvec::SmallVec;
 use tracing::{Instrument, Level};
-use turbo_frozenmap::FrozenMap;
+use turbo_frozenmap::{FrozenMap, FrozenSet};
 use turbo_rcstr::{RcStr, rcstr};
 use turbo_tasks::{
     FxIndexMap, FxIndexSet, NonLocalValue, ReadRef, ResolvedVc, SliceMap, TaskInput,
@@ -129,7 +128,7 @@ pub enum ImportUsage {
     ///
     /// (This is only ever set on `ModulePart::Export` references. Side effects are handled via
     /// `ModulePart::Evaluation` references, which always have `ImportUsage::SideEffects`.)
-    Exports(AutoSet<RcStr>),
+    Exports(FrozenSet<RcStr>),
 }
 
 #[turbo_tasks::value]
Repository: ollama/ollama
Pull request: runner.go: Fix off-by-one for num predicted


Changed files:
filename: llama/runner/runner.go
patch: @@ -345,7 +345,7 @@ func (s *Server) processBatch(tokenBatch *llama.Batch, embedBatch *llama.Batch)
 		}
 
 		// if past the num predict limit
-		if seq.numPredict > 0 && seq.numPredicted > seq.numPredict {
+		if seq.numPredict > 0 && seq.numPredicted >= seq.numPredict {
 			s.removeSequence(seqIdx, "limit")
 			continue
 		}
Repository: huggingface/transformers
Pull request: Only default `rope_parameters` to empty `dict` if there is something to put in it

`set(rope_parameters.keys()).issubset(self.layer_types)` will evaluate to `True` if `rope_parameters` is an empty `dict`.

This is a problem if `standardise_rope_params` is called on a config for a model which do not have RoPE because it will trigger `Case 2`. This method might be called on models which do not have RoPE in third party libraries (e.g. vLLM) in order to "upgrade" configs of custom models they use.

This PR makes `standardise_rope_params` harmless to call on configs with no RoPE at all.

Changed files:
filename: src/transformers/modeling_rope_utils.py
patch: @@ -654,20 +654,26 @@ def standardize_rope_params(self):
         Helper to standardize the config's rope params field by ensuring the params are defined for each
         later type. For old model the fn will duplicate a single rope param in each layer type (backward compatibility)
         """
-        # Move `rope_theta` and `partial_rotary_factor` to the params dict, if not there yet
+        # Move `rope_theta` and `partial_rotary_factor` to the `rope_parameters`, if not there yet
         rope_theta = getattr(self, "rope_theta", None)
         partial_rotary_factor = getattr(self, "partial_rotary_factor", None)
         rope_parameters = getattr(self, "rope_parameters", None) or {}
+        layer_types = getattr(self, "layer_types", None)
 
+        # Case 0: no RoPE params defined
+        if not (rope_parameters or rope_theta):
+            # partial_rotary_factor without rope_theta is invalid, so we don't check for it here
+            logger.warning("`standardize_rope_params` was called but no RoPE parameters were found.")
+            return
         # Case 1: RoPE param keys do not intersect with possible `layer_types` -> one global dict
-        if getattr(self, "layer_types", None) is None or not set(rope_parameters.keys()).issubset(self.layer_types):
+        elif layer_types is None or rope_parameters == {} or not set(rope_parameters.keys()).issubset(layer_types):
             rope_parameters.setdefault("rope_type", rope_parameters.get("type", "default"))
             rope_parameters.setdefault("rope_theta", rope_theta)
             if partial_rotary_factor is not None:
                 rope_parameters["partial_rotary_factor"] = partial_rotary_factor
         # Case 2: different RoPE for each layer -> several params as nested dict
         else:
-            for layer_type in self.layer_types:
+            for layer_type in layer_types:
                 rope_parameters[layer_type].setdefault("rope_type", rope_parameters[layer_type].get("type", "default"))
                 rope_parameters[layer_type].setdefault("rope_theta", rope_theta)
                 if partial_rotary_factor is not None:
Repository: electron/electron
Pull request: fix: restore window's canHide property on macOS

Backport of #47970

See that PR for details.


Notes: Restored window's canHide property

Changed files:
filename: shell/browser/browser_mac.mm
patch: @@ -546,6 +546,9 @@ LoginItemSettings GetLoginItemSettingsDeprecated() {
   gin_helper::Promise<void> promise(isolate);
   v8::Local<v8::Promise> handle = promise.GetHandle();
 
+  for (auto* const& window : WindowList::GetWindows())
+    [window->GetNativeWindow().GetNativeNSWindow() setCanHide:YES];
+
   BOOL active = [[NSRunningApplication currentApplication] isActive];
   ProcessSerialNumber psn = {0, kCurrentProcess};
   if (active) {
Repository: huggingface/transformers
Pull request: Stricter checks for mistral patch

# What does this PR do?
Fixes #42591

Changed files:
filename: src/transformers/tokenization_utils_tokenizers.py
patch: @@ -1193,7 +1193,7 @@ def is_base_mistral(model_id: str) -> bool:
                         ]
                     ):
                         return tokenizer
-                elif transformers_version and version.parse(transformers_version) >= version.parse("4.57.3"):
+                elif transformers_version and version.parse(transformers_version) > version.parse("4.57.3"):
                     return tokenizer
 
                 mistral_config_detected = True
Repository: facebook/react
Pull request: [ci] Add cache cleanup workflow


> Caches have branch scope restriction in place. This means that if caches for a specific branch are using a lot of storage quota, it may result into more frequently used caches from default branch getting thrashed. For example, if there are many pull requests happening on a repo and are creating caches, these cannot be used in default branch scope but will still occupy a lot of space till they get cleaned up by eviction policy. But sometime we want to clean them up on a faster cadence so as to ensure default branch is not thrashing.

https://github.com/actions/cache/blob/main/tips-and-workarounds.md#force-deletion-of-caches-overriding-default-cache-eviction-policy
---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed with [ReviewStack](https://reviewstack.dev/facebook/react/pull/32675).
* __->__ #32675
* #32674

Changed files:
filename: .github/workflows/shared_cleanup_branch_caches.yml
patch: @@ -0,0 +1,35 @@
+# https://github.com/actions/cache/blob/main/tips-and-workarounds.md#force-deletion-of-caches-overriding-default-cache-eviction-policy
+
+name: (Shared) Cleanup Branch Caches
+on:
+  pull_request:
+    types:
+      - closed
+  workflow_dispatch:
+
+jobs:
+  cleanup:
+    runs-on: ubuntu-latest
+    permissions:
+      # `actions:write` permission is required to delete caches
+      #   See also: https://docs.github.com/en/rest/actions/cache?apiVersion=2022-11-28#delete-a-github-actions-cache-for-a-repository-using-a-cache-id
+      actions: write
+      contents: read
+    steps:
+      - name: Cleanup
+        run: |
+          echo "Fetching list of cache key"
+          cacheKeysForPR=$(gh cache list --ref $BRANCH --limit 100 --json id --jq '.[].id')
+
+          ## Setting this to not fail the workflow while deleting cache keys.
+          set +e
+          echo "Deleting caches..."
+          for cacheKey in $cacheKeysForPR
+          do
+              gh cache delete $cacheKey
+          done
+          echo "Done"
+        env:
+          GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+          GH_REPO: ${{ github.repository }}
+          BRANCH: refs/pull/${{ github.event.pull_request.number }}/merge
Repository: ggml-org/llama.cpp
Pull request: model-conversion : make printing of config values optional

This commit updates run-org-model.py to make the printing of model configuration values optional.

The motivation for this change is that not all models have these configuration values defined and those that do not will error when running this script. With these changes we only print the values if they exist.

We could optionally just remove them but it can be useful to see these values when running the original model.

Changed files:
filename: examples/model-conversion/scripts/causal/run-org-model.py
patch: @@ -42,11 +42,15 @@ def load_model_and_tokenizer(model_path, device="auto"):
         config = config.text_config
         multimodal = True
 
-    print("Vocab size:       ", config.vocab_size)
-    print("Hidden size:      ", config.hidden_size)
-    print("Number of layers: ", config.num_hidden_layers)
-    print("BOS token id:     ", config.bos_token_id)
-    print("EOS token id:     ", config.eos_token_id)
+    def print_if_exists(label, obj, attr, default="N/A"):
+        val = getattr(obj, attr) if hasattr(obj, attr) else default
+        print(f"{label}", val)
+
+    print_if_exists("Vocab size:       ", config, "vocab_size")
+    print_if_exists("Hidden size:      ", config, "hidden_size")
+    print_if_exists("Number of layers: ", config, "num_hidden_layers")
+    print_if_exists("BOS token id:     ", config, "bos_token_id")
+    print_if_exists("EOS token id:     ", config, "eos_token_id")
 
     unreleased_model_name = os.getenv("UNRELEASED_MODEL_NAME")
     if unreleased_model_name:
Repository: vuejs/vue
Pull request: correct variable name

<!--
Please make sure to read the Pull Request Guidelines:
https://github.com/vuejs/vue/blob/dev/.github/CONTRIBUTING.md#pull-request-guidelines
-->

<!-- PULL REQUEST TEMPLATE -->
<!-- (Update "[ ]" to "[x]" to check a box) -->

**What kind of change does this PR introduce?** (check at least one)

- [x] Bugfix
- [ ] Feature
- [ ] Code style update
- [ ] Refactor
- [ ] Build-related changes
- [ ] Other, please describe:

**Does this PR introduce a breaking change?** (check one)

- [ ] Yes
- [x] No

If yes, please describe the impact and migration path for existing applications:

**The PR fulfills these requirements:**

- [x] It's submitted to the `dev` branch for v2.x (or to a previous version branch), _not_ the `master` branch
- [ ] When resolving a specific issue, it's referenced in the PR's title (e.g. `fix #xxx[,#xxx]`, where "xxx" is the issue number)
- [x] All tests are passing: https://github.com/vuejs/vue/blob/dev/.github/CONTRIBUTING.md#development-setup
- [ ] New/updated tests are included

If adding a **new feature**, the PR's description includes:
- [ ] A convincing reason for adding this feature (to avoid wasting your time, it's best to open a suggestion issue first and wait for approval before working on it)

**Other information:**


Changed files:
filename: src/server/template-renderer/index.js
patch: @@ -217,7 +217,7 @@ export default class TemplateRenderer {
   }
 
   getUsedAsyncFiles (context: Object): ?Array<string> {
-    if (!context._mappedfiles && context._registeredComponents && this.mapFiles) {
+    if (!context._mappedFiles && context._registeredComponents && this.mapFiles) {
       context._mappedFiles = this.mapFiles(Array.from(context._registeredComponents))
     }
     return context._mappedFiles
Repository: ollama/ollama
Pull request: CI: give windows lint more time

It looks like 8 minutes isn't quite enough and we're seeing sporadic timeouts

Changed files:
filename: .github/workflows/test.yaml
patch: @@ -281,7 +281,7 @@ jobs:
         shell: bash
       - uses: golangci/golangci-lint-action@v6
         with:
-          args: --timeout 8m0s -v
+          args: --timeout 10m0s -v
   test:
     strategy:
       matrix:
Repository: ollama/ollama
Pull request: doc: capture numeric group requirement

Docker uses the container filesystem for name resolution, so we can't guide users to use the name of the host group.  Instead they must specify the numeric ID.

Ref #6685 

Changed files:
filename: docs/troubleshooting.md
patch: @@ -95,7 +95,7 @@ If none of those resolve the problem, gather additional information and file an
 
 On linux, AMD GPU access typically requires `video` and/or `render` group membership to access the `/dev/kfd` device.  If permissions are not set up correctly, Ollama will detect this and report an error in the server log.
 
-When running in a container, in some Linux distributions and container runtimes, the ollama process may be unable to access the GPU.  Use `ls -ld /dev/kfd /dev/dri /dev/dri/*` on the host system to determine the group assignments on your system, and pass additional `--group-add ...` arguments to the container so it can access the required devices.
+When running in a container, in some Linux distributions and container runtimes, the ollama process may be unable to access the GPU.  Use `ls -lnd /dev/kfd /dev/dri /dev/dri/*` on the host system to determine the **numeric** group IDs on your system, and pass additional `--group-add ...` arguments to the container so it can access the required devices.   For example, in the following output `crw-rw---- 1 0  44 226,   0 Sep 16 16:55 /dev/dri/card0` the group ID column is `44` 
 
 If Ollama initially works on the GPU in a docker container, but then switches to running on CPU after some period of time with errors in the server log reporting GPU discovery failures, this can be resolved by disabling systemd cgroup management in Docker.  Edit `/etc/docker/daemon.json` on the host and add `"exec-opts": ["native.cgroupdriver=cgroupfs"]` to the docker configuration.