helloadhavan/github_issues huggingface dataset:
Repository: vercel/next.js
Pull request: Turbopack: include more details in panic

<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation

- Run `pnpm prettier-fix` to fix formatting issues before opening the PR.
- Read the Docs Contribution Guide to ensure your contribution follows the docs guidelines: https://nextjs.org/docs/community/contribution-guide

### Adding or Updating Examples

- The "examples guidelines" are followed from our contributing doc https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- Make sure the linting passes by running `pnpm build && pnpm lint`. See https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See: https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. (A discussion must be opened, see https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added (https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs)
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see https://github.com/vercel/next.js/blob/canary/contributing.md


## For Maintainers

- Minimal description (aim for explaining to someone not on the team to understand the PR)
- When linking to a Slack thread, you might want to share details of the conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->


Closes PACK-5089

Changed files:
filename: turbopack/crates/turbopack-ecmascript/src/lib.rs
patch: @@ -2430,7 +2430,10 @@ impl CodeGenResultComments {
         } else if old_high_bits == 0 {
             false
         } else {
-            panic!("The high bits of the position {pos} are not all 0s or 1s: {old_high_bits:b}",);
+            panic!(
+                "The high bits of the position {pos} are not all 0s or 1s. \
+                 modules_header_width={modules_header_width}, module={module}",
+            );
         };
 
         let pos = pos & !((2u32.pow(header_width) - 1) << pos_width);
Repository: huggingface/transformers
Pull request: Allow `device_mesh` have multiple dim 

Experimental PR for me to just make stuff work on the accelerate side, will follow up with this after.

Changed files:
filename: src/transformers/modeling_utils.py
patch: @@ -4581,6 +4581,7 @@ def from_pretrained(
                 A torch tensor parallel degree. If not provided would default to world size.
             device_mesh (`torch.distributed.DeviceMesh`, *optional*):
                 A torch device mesh. If not provided would default to world size. Used only for tensor parallel for now.
+                If provided, it has to contain dimension named `"tp"` which will be used for tensor parallelism
             offload_folder (`str` or `os.PathLike`, *optional*):
                 If the `device_map` contains any value `"disk"`, the folder where we will offload weights.
             offload_state_dict (`bool`, *optional*):
@@ -4718,13 +4719,17 @@ def from_pretrained(
         # We need to correctly dispatch the model on the current process device. The easiest way for this is to use a simple
         # `device_map` pointing to the correct device
         if tp_plan is not None:
-            if device_mesh is None and tp_plan is not None:
+            if device_mesh is None:
                 tp_plan, device_map, device_mesh = initialize_tensor_parallelism(tp_plan, tp_size=None)
             else:
-                # TODO: make device_mesh support multiple dimensions
-                if device_mesh.ndim != 1:
-                    raise ValueError("device_mesh must be 1 dimensional and will be used for TP")
-                device_map = torch.device(device_mesh.device_type, int(os.environ["LOCAL_RANK"]))
+                if "tp" not in device_mesh.mesh_dim_names:
+                    raise ValueError(
+                        "When using `tp_plan`, the `device_mesh` must contain a 'tp' dimension. "
+                        "Please provide a valid `device_mesh`."
+                    )
+                device_mesh = device_mesh["tp"]
+                tp_size = device_mesh["tp"].size()
+                device_map = torch.device(f"{device_mesh.device_type}:{int(os.environ['LOCAL_RANK'])}")
 
             if tp_size is None:
                 tp_size = torch.distributed.get_world_size()
Repository: ggml-org/llama.cpp
Pull request: codeowners : claim responsibility for ci, models, gguf-py and convert

I'm willing to claim responsibility for reviewing and maintaining various bits I've come to know in a fair amount of detail. If desirable by the individuals in question I feel I should append the following people to these:

* /.github/workflows/ @slaren @danbev
* /gguf-py/ @compilade 
* /convert_*.py @compilade
* requirements*.txt @compilade

I'm also willing to claim more, f.ex. model specific files in `/src`, however it's probably not a good idea to add too many lines to `CODEOWNERS`, and in almost all cases I will get pulled into those PRs anyway.

Changed files:
filename: CODEOWNERS
patch: @@ -10,3 +10,12 @@
 /ggml/src/gguf.cpp @JohannesGaessler
 /ggml/src/ggml-vulkan/ @0cc4m
 /ggml/src/ggml-zdnn/ @taronaeo
+/.github/workflows/ @CISC
+/src/llama-adapter.* @CISC
+/src/llama-arch.* @CISC
+/src/llama-graph.* @CISC
+/src/llama-model.* @CISC
+/src/llama-vocab.* @CISC
+/gguf-py/ @CISC
+/convert_*.py @CISC
+requirements*.txt @CISC
Repository: ggml-org/llama.cpp
Pull request: ci : remove vulkaninfo calls

I think these calls seem to get stuck when the virtual GPU is not available.

Changed files:
filename: .github/workflows/build.yml
patch: @@ -1396,7 +1396,6 @@ jobs:
       - name: Test
         id: ggml-ci
         run: |
-          vulkaninfo
           GG_BUILD_VULKAN=1 bash ./ci/run.sh ~/results/llama.cpp /mnt/llama.cpp
 
   ggml-ci-x64-amd-v710-rocm:
@@ -1410,7 +1409,6 @@ jobs:
       - name: Test
         id: ggml-ci
         run: |
-          vulkaninfo
           GG_BUILD_ROCM=1 GG_BUILD_AMDGPU_TARGETS="gfx1101" bash ./ci/run.sh ~/results/llama.cpp /mnt/llama.cpp
 
   ggml-ci-mac-metal:
Repository: denoland/deno
Pull request: fix(lsp): do not warn about unscoped package name

It's useful to just use a bare specifier for the package name in a workspace when not publishing to JSR.

Changed files:
filename: cli/schemas/config-file.v1.json
patch: @@ -709,8 +709,7 @@
     },
     "name": {
       "type": "string",
-      "description": "The name of this JSR package. Must be scoped",
-      "pattern": "^@[a-z0-9-]+/[a-z0-9-]+$"
+      "description": "The name of this JSR or workspace package."
     },
     "version": {
       "type": "string",
Repository: electron/electron
Pull request: fix: package import existence verification

#### Description of Change

Closes https://github.com/electron/electron/issues/45896.

Small but critical error not caught as we don't test for this. Adding a test will be a bit complex and I'll follow this up with that but it's blocking enough that we should perhaps not pend on it.

#### Checklist
<!-- Remove items that do not apply. For completed items, change [ ] to [x]. -->

- [x] PR description included and stakeholders cc'd
- [x] `npm test` passes
- [x] [PR release notes](https://github.com/electron/clerk/blob/main/README.md) describe the change in a way relevant to app developers, and are [capitalized, punctuated, and past tense](https://github.com/electron/clerk/blob/main/README.md#examples).

#### Release Notes

Notes: Fixed an issue where packages could be mistakenly not found in asar.


Changed files:
filename: patches/node/fix_allow_passing_fileexists_fn_to_legacymainresolve.patch
patch: @@ -53,7 +53,7 @@ index 2879e5cf541fb4d226cfd7cc0fe367ca448fb926..03082f0ec4f91382933eec48e77331cd
    const maybeMain = resolvedOption <= legacyMainResolveExtensionsIndexes.kResolvedByMainIndexNode ?
      packageConfig.main || './' : '';
 diff --git a/src/node_file.cc b/src/node_file.cc
-index 1d22e19f16d5ad82466b0724971b2e4a685682f7..9619d10710ffbbdc73fa7d59d1b797c8d0b3a956 100644
+index 1d22e19f16d5ad82466b0724971b2e4a685682f7..3d7e303741a73134e140152bed637fe5ae8bc1db 100644
 --- a/src/node_file.cc
 +++ b/src/node_file.cc
 @@ -3220,13 +3220,25 @@ static void CpSyncCheckPaths(const FunctionCallbackInfo<Value>& args) {
@@ -73,7 +73,7 @@ index 1d22e19f16d5ad82466b0724971b2e4a685682f7..9619d10710ffbbdc73fa7d59d1b797c8
 +        env->isolate(), file_path.c_str(), v8::NewStringType::kNormal)
 +                                       .ToLocalChecked()};
 +    MaybeLocal<Value> maybe_is_file = is_file_function->Call(env->context(), v8::Undefined(env->isolate()), 1, argv);
-+    if (maybe_is_file.IsEmpty()) {
++    if (!maybe_is_file.IsEmpty()) {
 +      bool is_file = maybe_is_file.ToLocalChecked()->BooleanValue(env->isolate());
 +      return is_file ? BindingData::FilePathIsFileReturnType::kIsFile
 +                    : BindingData::FilePathIsFileReturnType::kIsNotFile;

filename: patches/node/src_stop_using_deprecated_fields_of_fastapicallbackoptions.patch
patch: @@ -40,7 +40,7 @@ index 0f0cde7be431dcb80c5314b1a9da49886c436d1c..f6d2bd439cad8b9f91c9d9a6cdb302e6
    }
    HistogramBase* histogram;
 diff --git a/src/node_file.cc b/src/node_file.cc
-index 9619d10710ffbbdc73fa7d59d1b797c8d0b3a956..f2a5c0939b60c582dbbecc07add1e903a9183b95 100644
+index 3d7e303741a73134e140152bed637fe5ae8bc1db..5e744bc34b9dc364e8f20adfd37ee41d76451170 100644
 --- a/src/node_file.cc
 +++ b/src/node_file.cc
 @@ -1061,13 +1061,8 @@ static int32_t FastInternalModuleStat(
Repository: facebook/react
Pull request: [flow] ignore hidden directories

[flow] ignore hidden directories


Changed files:
filename: scripts/flow/config/flowconfig
patch: @@ -2,7 +2,8 @@
 .*/scripts/bench/.*
 .*/build/.*
 .*/fixtures/.*
-.*/.tempUserDataDir/.*
+# Any hidden directory
+.*/\..*
 
 # These shims are copied into external projects:
 .*/rollup/shims/facebook-www/.*
Repository: nodejs/node
Pull request: test_runner: fix TypeError exception when --enable-source-maps is passed

Split of #55228 

Changed files:
filename: lib/internal/test_runner/test.js
patch: @@ -560,7 +560,7 @@ class Test extends AsyncResource {
         const map = lazyFindSourceMap(this.loc.file);
         const entry = map?.findEntry(this.loc.line - 1, this.loc.column - 1);
 
-        if (entry !== undefined) {
+        if (entry?.originalSource !== undefined) {
           this.loc.line = entry.originalLine + 1;
           this.loc.column = entry.originalColumn + 1;
           this.loc.file = entry.originalSource;

filename: test/parallel/test-runner-enable-source-maps-issue.js
patch: @@ -0,0 +1,16 @@
+'use strict';
+require('../common');
+const assert = require('node:assert');
+const { spawnSync } = require('node:child_process');
+const { test } = require('node:test');
+const fixtures = require('../common/fixtures');
+
+test('ensures --enable-source-maps does not throw an error', () => {
+  const fixture = fixtures.path('test-runner', 'coverage', 'stdin.test.js');
+  const args = ['--enable-source-maps', fixture];
+
+  const result = spawnSync(process.execPath, args);
+
+  assert.strictEqual(result.stderr.toString(), '');
+  assert.strictEqual(result.status, 0);
+});
Repository: electron/electron
Pull request: fix: package import existence verification

Backport of #45997

See that PR for details.


Notes: Fixed an issue where packages could be mistakenly not found in asar.


Changed files:
filename: patches/node/fix_allow_passing_fileexists_fn_to_legacymainresolve.patch
patch: @@ -53,7 +53,7 @@ index 2879e5cf541fb4d226cfd7cc0fe367ca448fb926..03082f0ec4f91382933eec48e77331cd
    const maybeMain = resolvedOption <= legacyMainResolveExtensionsIndexes.kResolvedByMainIndexNode ?
      packageConfig.main || './' : '';
 diff --git a/src/node_file.cc b/src/node_file.cc
-index 1d22e19f16d5ad82466b0724971b2e4a685682f7..9619d10710ffbbdc73fa7d59d1b797c8d0b3a956 100644
+index 1d22e19f16d5ad82466b0724971b2e4a685682f7..3d7e303741a73134e140152bed637fe5ae8bc1db 100644
 --- a/src/node_file.cc
 +++ b/src/node_file.cc
 @@ -3220,13 +3220,25 @@ static void CpSyncCheckPaths(const FunctionCallbackInfo<Value>& args) {
@@ -73,7 +73,7 @@ index 1d22e19f16d5ad82466b0724971b2e4a685682f7..9619d10710ffbbdc73fa7d59d1b797c8
 +        env->isolate(), file_path.c_str(), v8::NewStringType::kNormal)
 +                                       .ToLocalChecked()};
 +    MaybeLocal<Value> maybe_is_file = is_file_function->Call(env->context(), v8::Undefined(env->isolate()), 1, argv);
-+    if (maybe_is_file.IsEmpty()) {
++    if (!maybe_is_file.IsEmpty()) {
 +      bool is_file = maybe_is_file.ToLocalChecked()->BooleanValue(env->isolate());
 +      return is_file ? BindingData::FilePathIsFileReturnType::kIsFile
 +                    : BindingData::FilePathIsFileReturnType::kIsNotFile;

filename: patches/node/src_stop_using_deprecated_fields_of_fastapicallbackoptions.patch
patch: @@ -40,7 +40,7 @@ index 0f0cde7be431dcb80c5314b1a9da49886c436d1c..f6d2bd439cad8b9f91c9d9a6cdb302e6
    }
    HistogramBase* histogram;
 diff --git a/src/node_file.cc b/src/node_file.cc
-index 9619d10710ffbbdc73fa7d59d1b797c8d0b3a956..f2a5c0939b60c582dbbecc07add1e903a9183b95 100644
+index 3d7e303741a73134e140152bed637fe5ae8bc1db..5e744bc34b9dc364e8f20adfd37ee41d76451170 100644
 --- a/src/node_file.cc
 +++ b/src/node_file.cc
 @@ -1061,13 +1061,8 @@ static int32_t FastInternalModuleStat(
Repository: denoland/deno
Pull request: fix(compile): init dummy stdin after debug env is initialized

This should be the last change to fix https://github.com/denoland/deno/issues/27730 and https://github.com/denoland/deno/issues/21091

The dummy stdin needed when using `--no-terminal` instantly closes, but closing can't be done until the debug environment is initialized.

This PR delays creation (and closing) of the stdin until after the debug environment is initialized.

Changed files:
filename: ext/node/polyfills/process.ts
patch: @@ -996,12 +996,6 @@ internals.__bootstrapNodeProcess = function (
     core.setMacrotaskCallback(runNextTicks);
     enableNextTick();
 
-    // Replace stdin if it is not a terminal
-    const newStdin = initStdin();
-    if (newStdin) {
-      stdin = process.stdin = newStdin;
-    }
-
     // Replace stdout/stderr if they are not terminals
     if (!io.stdout.isTerminal()) {
       /** https://nodejs.org/api/process.html#process_process_stdout */
@@ -1025,6 +1019,12 @@ internals.__bootstrapNodeProcess = function (
 
     initializeDebugEnv(nodeDebug);
 
+    // Replace stdin if it is not a terminal
+    const newStdin = initStdin();
+    if (newStdin) {
+      stdin = process.stdin = newStdin;
+    }
+
     delete internals.__bootstrapNodeProcess;
   } else {
     // Warmup, assuming stdin/stdout/stderr are all terminals
Repository: huggingface/transformers
Pull request: Fix tied weight test

# What does this PR do?

No reason to force to tie the embeddings, as then the test will fail for models that do NOT tie the weights by default


Changed files:
filename: tests/test_modeling_common.py
patch: @@ -2565,7 +2565,6 @@ def test_load_save_without_tied_weights(self):
 
     def test_tied_weights_keys(self):
         config, _ = self.model_tester.prepare_config_and_inputs_for_common()
-        config.get_text_config().tie_word_embeddings = True
         for model_class in self.all_model_classes:
             model_tied = model_class(copy.deepcopy(config))
Repository: ggml-org/llama.cpp
Pull request: ci : add label for the RISC-V runner

ref https://github.com/ggml-org/llama.cpp/pull/15386#issuecomment-3314976228

Changed files:
filename: .github/workflows/build-riscv-native.yml
patch: @@ -6,7 +6,7 @@ on:
 
 jobs:
   debian-13-riscv64-native: # Bianbu 2.2
-    runs-on: self-hosted
+    runs-on: [self-hosted, RISCV64]
 
     steps:
       - name: Install prerequisites
Repository: nodejs/node
Pull request: net: emit an error when custom lookup resolves a non-string address

Fixes: #57112

This PR fixes the crash when the lookup function resolves to a non-string address. Instead, it will emit an ERR_INVALID_IP_ADDRESS error. 

Changed files:
filename: lib/net.js
patch: @@ -1416,7 +1416,7 @@ function lookupAndConnect(self, options) {
         // calls net.Socket.connect() on it (that's us). There are no event
         // listeners registered yet so defer the error event to the next tick.
         process.nextTick(connectErrorNT, self, err);
-      } else if (!isIP(ip)) {
+      } else if ((typeof ip !== 'string') || !isIP(ip)) {
         err = new ERR_INVALID_IP_ADDRESS(ip);
         process.nextTick(connectErrorNT, self, err);
       } else if (addressType !== 4 && addressType !== 6) {

filename: test/parallel/test-net-connect-custom-lookup-non-string-address.mjs
patch: @@ -0,0 +1,44 @@
+import * as common from '../common/index.mjs';
+import net from 'node:net';
+import { describe, it } from 'node:test';
+
+const brokenCustomLookup = (_hostname, options, callback) => {
+  // Incorrectly return an array of IPs instead of a string.
+  callback(null, ['127.0.0.1'], options.family);
+};
+
+describe('when family is ipv4', () => {
+  it('socket emits an error when lookup does not return a string', (t, done) => {
+    const options = {
+      host: 'example.com',
+      port: 80,
+      lookup: brokenCustomLookup,
+      family: 4
+    };
+
+    const socket = net.connect(options, common.mustNotCall());
+    socket.on('error', (err) => {
+      t.assert.strictEqual(err.code, 'ERR_INVALID_IP_ADDRESS');
+
+      done();
+    });
+  });
+});
+
+describe('when family is ipv6', () => {
+  it('socket emits an error when lookup does not return a string', (t, done) => {
+    const options = {
+      host: 'example.com',
+      port: 80,
+      lookup: brokenCustomLookup,
+      family: 6
+    };
+
+    const socket = net.connect(options, common.mustNotCall());
+    socket.on('error', (err) => {
+      t.assert.strictEqual(err.code, 'ERR_INVALID_IP_ADDRESS');
+
+      done();
+    });
+  });
+});
Repository: ggml-org/llama.cpp
Pull request: vulkan: fix validation error about VK_PIPELINE_CREATE_CAPTURE_STATISTICS_BIT_KHR


Changed files:
filename: ggml/src/ggml-vulkan/ggml-vulkan.cpp
patch: @@ -1584,7 +1584,9 @@ static void ggml_vk_create_pipeline_func(vk_device& device, vk_pipeline& pipelin
     }
 
     vk::ComputePipelineCreateInfo compute_pipeline_create_info(
-        vk::PipelineCreateFlags{},
+        device->pipeline_executable_properties_support ?
+            vk::PipelineCreateFlagBits::eCaptureStatisticsKHR :
+            vk::PipelineCreateFlags{},
         pipeline_shader_create_info,
         pipeline->layout);
Repository: electron/electron
Pull request: fix: correct electron gin embedder indices (33-x-y)

Manually backport #45389 to 33-x-y. See that PR for details.

Notes: Fixed invalid memory access in pdf viewer which lead to random crashes.

Changed files:
filename: patches/chromium/fix_harden_blink_scriptstate_maybefrom.patch
patch: @@ -40,18 +40,18 @@ accessing uninitialized lower indexes can return garbage values that cannot be n
 Refer to v8::EmbedderDataSlot::store_aligned_pointer for context.
 
 diff --git a/gin/public/gin_embedders.h b/gin/public/gin_embedders.h
-index 8d7c5631fd8f1499c67384286f0e3c4037673b32..99b2e2f63be8a46c5546dd53bc9b05e8c54e857c 100644
+index 8d7c5631fd8f1499c67384286f0e3c4037673b32..2b7bdfbac06a42e6bc51eb65e023c3673e6eb885 100644
 --- a/gin/public/gin_embedders.h
 +++ b/gin/public/gin_embedders.h
-@@ -18,6 +18,8 @@ namespace gin {
- enum GinEmbedder : uint16_t {
-   kEmbedderNativeGin,
+@@ -20,6 +20,8 @@ enum GinEmbedder : uint16_t {
    kEmbedderBlink,
-+  kEmbedderElectron,
-+  kEmbedderBlinkTag,
    kEmbedderPDFium,
    kEmbedderFuchsia,
++  kEmbedderElectron,
++  kEmbedderBlinkTag,
  };
+
+ }  // namespace gin
 diff --git a/third_party/blink/renderer/platform/bindings/script_state.cc b/third_party/blink/renderer/platform/bindings/script_state.cc
 index e4a27a24c83dd1a478b2ada8b6c8220076790791..c76dc818f38a62fff63852dbecbc85e304ac731d 100644
 --- a/third_party/blink/renderer/platform/bindings/script_state.cc
@@ -86,7 +86,7 @@ index e4a27a24c83dd1a478b2ada8b6c8220076790791..c76dc818f38a62fff63852dbecbc85e3
  
    // Cut the reference from ScriptState to V8 context.
 diff --git a/third_party/blink/renderer/platform/bindings/script_state.h b/third_party/blink/renderer/platform/bindings/script_state.h
-index e9b16a9c71b9631222d0745428fea06be2e74472..aba4d930a9a45fb43e0aaac26af7df4fa07fc447 100644
+index e9b16a9c71b9631222d0745428fea06be2e74472..a85431a73bae23b5d47bc0338430c120de538864 100644
 --- a/third_party/blink/renderer/platform/bindings/script_state.h
 +++ b/third_party/blink/renderer/platform/bindings/script_state.h
 @@ -184,7 +184,12 @@ class PLATFORM_EXPORT ScriptState : public GarbageCollected<ScriptState> {
@@ -103,7 +103,7 @@ index e9b16a9c71b9631222d0745428fea06be2e74472..aba4d930a9a45fb43e0aaac26af7df4f
        return nullptr;
      }
      ScriptState* script_state =
-@@ -251,9 +256,15 @@ class PLATFORM_EXPORT ScriptState : public GarbageCollected<ScriptState> {
+@@ -251,9 +256,14 @@ class PLATFORM_EXPORT ScriptState : public GarbageCollected<ScriptState> {
    static void SetCreateCallback(CreateCallback);
    friend class ScriptStateImpl;
  
@@ -114,7 +114,6 @@ index e9b16a9c71b9631222d0745428fea06be2e74472..aba4d930a9a45fb43e0aaac26af7df4f
        static_cast<int>(gin::kEmbedderBlink);
 +  static constexpr int kV8ContextPerContextDataTagIndex =
 +      static_cast<int>(gin::kPerContextDataStartIndex) +
-+      static_cast<int>(gin::kEmbedderBlink) +
 +      static_cast<int>(gin::kEmbedderBlinkTag);
  };