helloadhavan/github_issues huggingface dataset:
Repository: ggml-org/llama.cpp
Pull request: Read the persisted llama_kv_cell_ext for n_pos_per_embd > 1 on state_read for all sequence ids

cont #20132

Attempting to call llama_kv_cache::state_read fails when n_pos_per_embd is greater than 1, since llama_kv_cell_ext data is serialised in `state_save` but not read back in `state_read`, leading to deserialisation failure since the cell_ext data is being parsed as a seq_id.

I assume the attached fix is correct -- kv cache persistence to host memory is now working as expected.


Changed files:
filename: src/llama-kv-cache.cpp
patch: @@ -1953,6 +1953,12 @@ bool llama_kv_cache::state_read_meta(llama_io_read_i & io, uint32_t strm, uint32
 
             cells.pos_set(i, pos);
 
+            if (hparams.n_pos_per_embd() > 1) {
+                llama_kv_cell_ext ext;
+                io.read_to(&ext, sizeof(ext));
+                cells.ext_set(i, ext);
+            }
+
             for (uint32_t j = 0; j < n_seq_id; ++j) {
                 llama_seq_id seq_id;
                 io.read_to(&seq_id, sizeof(seq_id));
Repository: nodejs/node
Pull request: doc: fix typos in issue template config

Minor tweaks


Changed files:
filename: .github/ISSUE_TEMPLATE/config.yml
patch: @@ -5,10 +5,10 @@ contact_links:
     about: Please file an issue in our help repo.
   - name: 📦 Have an issue with npm?
     url: https://github.com/npm/cli/issues
-    about: npm has a seperate issue tracker.
+    about: npm has a separate issue tracker.
   - name: 📡 Have an issue with undici? (`WebSocket`, `fetch`, etc.)
     url: https://github.com/nodejs/undici/issues
-    about: Undici has a seperate issue tracker.
+    about: Undici has a separate issue tracker.
   - name: 🌐 Found a problem with nodejs.org beyond the API reference docs?
     url: https://github.com/nodejs/nodejs.org/issues/new/choose
     about: Please file an issue in the Node.js website repo.
Repository: vuejs/vue
Pull request: [automated] Patreon sponsors update

This is an automated pull request.

Changed files:
filename: BACKERS.md
patch: @@ -163,7 +163,7 @@ Funds donated via Patreon go directly to support Evan You's full-time work on Vu
         </a>
       </td>
       <td align="center" valign="middle">
-        <a href="https://syncfusion.com/products/vue" target="_blank">
+        <a href="http://www.syncfusion.com/?utm_source=vuejs&utm_medium=list&utm_campaign=vuejsjslistcy19" target="_blank">
           <img width="148px" src="https://raw.githubusercontent.com/vuejs/vuejs.org/master/themes/vue/source/images/syncfusion.png">
         </a>
       </td>

filename: README.md
patch: @@ -168,7 +168,7 @@ Funds donated via Patreon go directly to support Evan You's full-time work on Vu
         </a>
       </td>
       <td align="center" valign="middle">
-        <a href="https://syncfusion.com/products/vue" target="_blank">
+        <a href="http://www.syncfusion.com/?utm_source=vuejs&utm_medium=list&utm_campaign=vuejsjslistcy19" target="_blank">
           <img width="148px" src="https://raw.githubusercontent.com/vuejs/vuejs.org/master/themes/vue/source/images/syncfusion.png">
         </a>
       </td>
Repository: vuejs/vue
Pull request: fix(#9511): avoid promise catch multiple times

<!--
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
- [x] 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
- [x] 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:**
fixed #9511 

In some cases, invokeWithErrorHandling will have nested calls, and Promise will independently catch multiple times, resulting in multiple calls to handleError.

Look at a sample code：

``` javascript
var p = Promise.reject('some err');

p.catch(() => console.log('1'));  // p = p.catch(...)
p.catch(() => console.log('2'));
```
The above code will output 1 and 2, but if you reassign the first catch call to p, it will not output 2.

Changed files:
filename: src/core/util/error.js
patch: @@ -44,7 +44,9 @@ export function invokeWithErrorHandling (
   try {
     res = args ? handler.apply(context, args) : handler.call(context)
     if (res && !res._isVue && isPromise(res)) {
-      res.catch(e => handleError(e, vm, info + ` (Promise/async)`))
+      // issue #9511
+      // reassign to res to avoid catch triggering multiple times when nested calls
+      res = res.catch(e => handleError(e, vm, info + ` (Promise/async)`))
     }
   } catch (e) {
     handleError(e, vm, info)

filename: test/unit/modules/util/invoke-with-error-handling.spec.js
patch: @@ -0,0 +1,23 @@
+import Vue from 'vue'
+import { invokeWithErrorHandling } from 'core/util/error'
+
+describe('invokeWithErrorHandling', () => {
+  if (typeof Promise !== 'undefined') {
+    it('should errorHandler call once when nested calls return rejected promise', done => {
+      let times = 0
+
+      Vue.config.errorHandler = function () {
+        times++
+      }
+
+      invokeWithErrorHandling(() => {
+        return invokeWithErrorHandling(() => {
+          return Promise.reject(new Error('fake error'))
+        })
+      }).then(() => {
+        expect(times).toBe(1)
+        done()
+      })
+    })
+  }
+})
Repository: vuejs/vue
Pull request: [automated] Patreon sponsors update

This is an automated pull request.

Changed files:
filename: BACKERS.md
patch: @@ -214,6 +214,11 @@ Funds donated via Patreon go directly to support Evan You's full-time work on Vu
           <img width="148px" src="https://raw.githubusercontent.com/vuejs/vuejs.org/master/themes/vue/source/images/bacancy_technology.png">
         </a>
       </td>
+      <td align="center" valign="middle">
+        <a href="https://passionatepeople.io/" target="_blank">
+          <img width="148px" src="https://raw.githubusercontent.com/vuejs/vuejs.org/master/themes/vue/source/images/passionate_people.png">
+        </a>
+      </td>
     </tr><tr></tr>
   </tbody>
 </table>

filename: README.md
patch: @@ -219,6 +219,11 @@ Funds donated via Patreon go directly to support Evan You's full-time work on Vu
           <img width="148px" src="https://raw.githubusercontent.com/vuejs/vuejs.org/master/themes/vue/source/images/bacancy_technology.png">
         </a>
       </td>
+      <td align="center" valign="middle">
+        <a href="https://passionatepeople.io/" target="_blank">
+          <img width="148px" src="https://raw.githubusercontent.com/vuejs/vuejs.org/master/themes/vue/source/images/passionate_people.png">
+        </a>
+      </td>
     </tr><tr></tr>
   </tbody>
 </table>
Repository: ollama/ollama
Pull request: ml: use input context for extracting outputs

Fixes https://github.com/ollama/ollama/issues/9863

Changed files:
filename: model/models/gemma2/model.go
patch: @@ -179,7 +179,7 @@ func (m *Model) Forward(ctx ml.Context, opts input.Options) (ml.Tensor, error) {
 		return nil, err
 	}
 
-	outputs, err := ctx.Output().FromIntSlice(opts.Outputs, len(opts.Outputs))
+	outputs, err := ctx.Input().FromIntSlice(opts.Outputs, len(opts.Outputs))
 	if err != nil {
 		return nil, err
 	}

filename: model/models/gemma3/model.go
patch: @@ -150,7 +150,7 @@ func (m *Model) Forward(ctx ml.Context, opts input.Options) (ml.Tensor, error) {
 		return nil, err
 	}
 
-	outputs, err := ctx.Output().FromIntSlice(opts.Outputs, len(opts.Outputs))
+	outputs, err := ctx.Input().FromIntSlice(opts.Outputs, len(opts.Outputs))
 	if err != nil {
 		return nil, err
 	}

filename: model/models/llama/model.go
patch: @@ -150,7 +150,7 @@ func (m *Model) Forward(ctx ml.Context, opts input.Options) (ml.Tensor, error) {
 		return nil, err
 	}
 
-	outputs, err := ctx.Output().FromIntSlice(opts.Outputs, len(opts.Outputs))
+	outputs, err := ctx.Input().FromIntSlice(opts.Outputs, len(opts.Outputs))
 	if err != nil {
 		return nil, err
 	}

filename: model/models/mllama/model.go
patch: @@ -154,7 +154,7 @@ func (m *Model) Forward(ctx ml.Context, opts input.Options) (ml.Tensor, error) {
 		return nil, err
 	}
 
-	outputs, err := ctx.Output().FromIntSlice(opts.Outputs, len(opts.Outputs))
+	outputs, err := ctx.Input().FromIntSlice(opts.Outputs, len(opts.Outputs))
 	if err != nil {
 		return nil, err
 	}
Repository: vercel/next.js
Pull request: fix typo

typo

Changed files:
filename: turbopack/crates/turbo-tasks-backend/src/backend/mod.rs
patch: @@ -1347,7 +1347,7 @@ impl<B: BackingStorage> TurboTasksBackendInner<B> {
                     .flatten()
             } {
                 // Task exists in backing storage
-                // So we only need to insert it into the in-memory cahce
+                // So we only need to insert it into the in-memory cache
                 self.track_cache_hit(&task_type);
                 let task_type = match raw_entry(&self.task_cache, &task_type) {
                     RawEntry::Occupied(_) => ArcOrOwned::Owned(task_type),
Repository: nodejs/node
Pull request: doc: add deprecation history for url.parse

url.parse should document its deprecation history, following DEP0169, for consistency.

https://github.com/nodejs/node/blob/2679b62e9155ea7d0849cd9ca5b380675aa29234/doc/api/deprecations.md#L3732-L3750

<!--
Before submitting a pull request, please read:

- the CONTRIBUTING guide at https://github.com/nodejs/node/blob/HEAD/CONTRIBUTING.md
- the commit message formatting guidelines at
  https://github.com/nodejs/node/blob/HEAD/doc/contributing/pull-requests.md#commit-message-guidelines

For code changes:
1. Include tests for any bug fixes or new features.
2. Update documentation if relevant.
3. Ensure that `make -j4 test` (UNIX), or `vcbuild test` (Windows) passes.

If you believe this PR should be highlighted in the Node.js CHANGELOG
please add the `notable-change` label.

Developer's Certificate of Origin 1.1

By making a contribution to this project, I certify that:

(a) The contribution was created in whole or in part by me and I
    have the right to submit it under the open source license
    indicated in the file; or

(b) The contribution is based upon previous work that, to the best
    of my knowledge, is covered under an appropriate open source
    license and I have the right under that license to submit that
    work with modifications, whether created in whole or in part
    by me, under the same open source license (unless I am
    permitted to submit under a different license), as indicated
    in the file; or

(c) The contribution was provided directly to me by some other
    person who certified (a), (b) or (c) and I have not modified
    it.

(d) I understand and agree that this project and the contribution
    are public and that a record of the contribution (including all
    personal information I submit with it, including my sign-off) is
    maintained indefinitely and may be redistributed consistent with
    this project or the open source license(s) involved.
-->


Changed files:
filename: doc/api/url.md
patch: @@ -1827,6 +1827,15 @@ npx codemod@latest @nodejs/node-url-to-whatwg-url
 <!-- YAML
 added: v0.1.25
 changes:
+  - version:
+      - v24.0.0
+    pr-url: https://github.com/nodejs/node/pull/55017
+    description: Application deprecation.
+  - version:
+      - v19.9.0
+      - v18.17.0
+    pr-url: https://github.com/nodejs/node/pull/47203
+    description: Added support for `--pending-deprecation`.
   - version:
       - v19.0.0
       - v18.13.0
Repository: ollama/ollama
Pull request: ggml: return error on failure to read tensor data

When converting a ggml model if there is a failure to read tensor data a nil error value was being returned. It should be assigned to the actual error from reading.

Changed files:
filename: ml/backend/ggml/ggml.go
patch: @@ -330,7 +330,7 @@ func New(r *os.File, params ml.BackendParams) (ml.Backend, error) {
 		}
 	}
 
-	if g.Wait() != nil {
+	if err := g.Wait(); err != nil {
 		return nil, err
 	}
Repository: ggml-org/llama.cpp
Pull request: devops: force Python 3.13 in Vulkan container

Forces Python 3.13 in the Vulkan container image build to support PyTorch 2.6.

Fixes #20524.

Changed files:
filename: .devops/vulkan.Dockerfile
patch: @@ -53,10 +53,11 @@ RUN apt-get update \
     && apt-get install -y \
     build-essential \
     git \
-    python3 \
-    python3-dev \
+    python3.13 \
+    python3.13-dev \
     python3-pip \
     python3-wheel \
+    && update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.13 100 \
     && pip install --break-system-packages --upgrade setuptools \
     && pip install --break-system-packages -r requirements.txt \
     && apt autoremove -y \
Repository: nodejs/node
Pull request: assert,util: fix deep comparison for sets and maps with mixed types

When comparing a Set or a Map and they contain primitives as keys as well as objects, the primitives would always be skipped. That is not correct, since that may only be skipped in case all keys are objects.

Fixes: https://github.com/nodejs/node/issues/61386


Changed files:
filename: lib/internal/util/comparisons.js
patch: @@ -669,8 +669,10 @@ function setObjectEquiv(array, a, b, mode, memo) {
         if (b.has(val1)) {
           continue;
         }
-      } else if (mode !== kLoose || b.has(val1)) {
+      } else if (b.has(val1)) {
         continue;
+      } else if (mode !== kLoose) {
+        return false;
       }
     }
 
@@ -816,11 +818,14 @@ function mapObjectEquiv(array, a, b, mode, memo) {
   const extraChecks = mode === kLoose || array.length !== a.size;
 
   for (const { 0: key1, 1: item1 } of a) {
-    if (extraChecks &&
-        (typeof key1 !== 'object' || key1 === null) &&
-        (mode !== kLoose ||
-          (b.has(key1) && innerDeepEqual(item1, b.get(key1), mode, memo)))) { // Mixed mode
-      continue;
+    if (extraChecks && (typeof key1 !== 'object' || key1 === null)) {
+      if (b.has(key1)) {
+        if (mode !== kLoose || innerDeepEqual(item1, b.get(key1), mode, memo)) {
+          continue;
+        }
+      } else if (mode !== kLoose) {
+        return false;
+      }
     }
 
     let innerStart = start;

filename: test/parallel/test-assert-deep.js
patch: @@ -634,6 +634,21 @@ test('Handle sparse arrays', () => {
   assertNotDeepOrStrict(a, b, AssertionError, { partial: 'pass' });
 });
 
+test('Handle sets and maps with mixed keys', () => {
+  // https://github.com/nodejs/node/issues/61386
+  const aSet = new Set([0, new Set([1, 2, 3]), new Set([4, 5, 6])]);
+  const bSet = new Set([
+    0,
+    new Set([1, new Set([2, 3]), new Set([20, 30])]),
+    new Set([4, new Set([5, 6]), new Set([50, 60])]),
+  ]);
+  assertNotDeepOrStrict(aSet, bSet);
+
+  const aMap = new Map([[0, 'zero'], [1, 'one'], [new Set([1, 2, 3]), 'A']]);
+  const bMap = new Map([[0, 'zero'], [new Set([1, 2, 3]), 'A'], [new Set([9]), 'B']]);
+  assertNotDeepOrStrict(aMap, bMap);
+});
+
 test('Handle different error messages', () => {
   const err1 = new Error('foo1');
   assertNotDeepOrStrict(err1, new Error('foo2'), assert.AssertionError);
Repository: vercel/next.js
Pull request: Turbopack: reduce cache size

### What?

do not persist EcmascriptChunkItemContent
It's already stored as part of the module factory

Changed files:
filename: turbopack/crates/turbopack-ecmascript/src/chunk/item.rs
patch: @@ -47,7 +47,9 @@ pub enum RewriteSourcePath {
     None,
 }
 
-#[turbo_tasks::value(shared)]
+// Note we don't want to persist this as `module_factory_with_code_generation_issue` is already
+// persisted and we want to avoid duplicating it.
+#[turbo_tasks::value(shared, serialization = "none")]
 #[derive(Default, Clone)]
 pub struct EcmascriptChunkItemContent {
     pub inner_code: Rope,
Repository: ollama/ollama
Pull request: convert: return name of unsupported architecture

When a model's architecture cannot be converted return the name of the unsupported arch in the error message.

Sample output:
```
copying file sha256:99c38a089b14a0fca228899132eb8db54ea551bdc96b639267d5177e4a172776 100%
converting model
Error: unsupported architecture "Mistral3ForConditionalGeneration"
```

Changed files:
filename: convert/convert.go
patch: @@ -201,7 +201,7 @@ func ConvertModel(fsys fs.FS, ws io.WriteSeeker) error {
 	case "CohereForCausalLM":
 		conv = &commandrModel{}
 	default:
-		return errors.New("unsupported architecture")
+		return fmt.Errorf("unsupported architecture %q", p.Architectures[0])
 	}
 
 	if err := json.Unmarshal(bts, conv); err != nil {
Repository: facebook/react
Pull request: Use brackets instead of parenthesis in empty name eval

Otherwise V8 will parse it as a URL and mess it up. The bracket is a magic string meaning empty.

Changed files:
filename: packages/react-client/src/ReactFlightClient.js
patch: @@ -1955,7 +1955,7 @@ function createFakeFunction<T>(
 
   if (!name) {
     // An eval:ed function with no name gets the name "eval". We give it something more descriptive.
-    name = '(anonymous)';
+    name = '<anonymous>';
   }
   const encodedName = JSON.stringify(name);
   // We generate code where the call is at the line and column of the server executed code.

filename: packages/react-client/src/__tests__/ReactFlight-test.js
patch: @@ -1285,8 +1285,8 @@ describe('ReactFlight', () => {
                   'Error: This is an error\n' +
                     '    at eval (eval at testFunction (eval at createFakeFunction (**), <anonymous>:1:35)\n' +
                     '    at ServerComponentError (file://~/(some)(really)(exotic-directory)/ReactFlight-test.js:1166:19)\n' +
-                    '    at (anonymous) (file:///testing.js:42:3)\n' +
-                    '    at (anonymous) (file:///testing.js:42:3)\n',
+                    '    at <anonymous> (file:///testing.js:42:3)\n' +
+                    '    at <anonymous> (file:///testing.js:42:3)\n',
                 )
               : expect.stringContaining(
                   'Error: This is an error\n' +
Repository: ollama/ollama
Pull request: conditionally enable parallel pipelines

parallel pipelines enables faster scheduling at the cost of more memory so only enable it when needed, which is when multiple devices are present and all layers are on the GPU, including the output layer

Changed files:
filename: ml/backend/ggml/ggml.go
patch: @@ -373,7 +373,7 @@ func New(r *os.File, params ml.BackendParams) (ml.Backend, error) {
 			(*C.ggml_backend_buffer_type_t)(unsafe.Pointer(&schedBufts[0])),
 			C.int(len(schedBackends)),
 			C.size_t(maxGraphNodes),
-			true,
+			C._Bool(len(gpus) > 1 && slices.Contains(gpus, output.d)),
 		),
 		input:  deviceBufferTypes[input.d],
 		output: deviceBufferTypes[output.d],
Repository: ollama/ollama
Pull request: ollamarunner: Check for minBatch of context space when shifting

Models can specify that a group of inputs need to be handled a single batch. However, context shifting didn't respect this and could trigger a break anyways. In this case, we should instead trigger a context shift earlier so that it occurs before the grouped batch.

Note that there still some corner cases:
 - A long prompt that exceeds the context window can get truncated in the middle of an image. With the current models, this will result in the model not recognizing the image at all, which is pretty much the expected result with truncation.
 - The context window is set less than the minimum batch size. The only solution to this is to refuse to load the model with these settings. However, this can never occur with current models and default settings.

Since users are unlikely to run into these scenarios, fixing them is left as a follow up.

Changed files:
filename: runner/ollamarunner/runner.go
patch: @@ -115,6 +115,9 @@ func (s *Server) NewSequence(prompt string, images []llm.ImageData, params NewSe
 		params.numKeep = int32(len(inputs))
 	}
 
+	// TODO(jessegross): We should ensure that we always leave minBatch of context space to shift,
+	// otherwise we might truncate or split the batch against the model's wishes
+
 	// Ensure that at least 1 input can be discarded during shift
 	params.numKeep = min(params.numKeep, s.cache.numCtx-1)
 
@@ -366,17 +369,6 @@ func (s *Server) processBatch() error {
 		batchSize := s.batchSize
 
 		for j, inp := range seq.inputs {
-			if int32(len(seq.cache.Inputs)+len(seq.pendingInputs)+1) > s.cache.numCtx {
-				if len(seq.pendingInputs) == 0 {
-					err := s.cache.ShiftCacheSlot(seq.cache, seq.numKeep)
-					if err != nil {
-						return err
-					}
-				} else {
-					break
-				}
-			}
-
 			// If we are required to put following inputs into a single batch then extend the
 			// batch size. Since we are only extending the size the minimum amount possible, this
 			// will cause a break if we have pending inputs.
@@ -389,6 +381,20 @@ func (s *Server) processBatch() error {
 				break
 			}
 
+			// If the sum of our working set (already processed tokens, tokens we added to this
+			// batch, required following tokens) exceeds the context size, then trigger a shift
+			// now so we don't have to do one later when we can't break the batch.
+			if int32(len(seq.cache.Inputs)+len(seq.pendingInputs)+minBatch) > s.cache.numCtx {
+				if len(seq.pendingInputs) != 0 {
+					break
+				}
+
+				err := s.cache.ShiftCacheSlot(seq.cache, seq.numKeep)
+				if err != nil {
+					return err
+				}
+			}
+
 			options.Inputs = append(options.Inputs, inp.Token)
 			if inp.Multimodal != nil {
 				options.Multimodal = append(options.Multimodal, input.MultimodalIndex{Index: len(options.Inputs) - 1, Multimodal: inp.Multimodal})
Repository: nodejs/node
Pull request: tools: fix vcbuild lint-js-build

Currently on Windows we cannot run `vcbuild.bat lint-js`  because the `lint-js-build` is skipped: after the `lint-cpp:` label we go to the `lint-js:` label. Since the `lint-js-build` is never run, we cannot run the `lint-js`.

This PR fixes the issue by going to `lint-js-build:` label after probing the `lint-cpp:` label.

It also fixes running the `vcbuild.bat lint-md` on Windows.

This change was originally added in the PR #60916, but it is better to address this issue in a separate PR.

Changed files:
filename: vcbuild.bat
patch: @@ -749,15 +749,15 @@ if errorlevel 1 goto exit
 goto lint-cpp
 
 :lint-cpp
-if not defined lint_cpp goto lint-js
+if not defined lint_cpp goto lint-js-build
 if defined NODEJS_MAKE goto run-make-lint
 where make > NUL 2>&1 && make -v | findstr /C:"GNU Make" 1> NUL
 if "%ERRORLEVEL%"=="0" set "NODEJS_MAKE=make PYTHON=python" & goto run-make-lint
 where wsl > NUL 2>&1
 if "%ERRORLEVEL%"=="0" set "NODEJS_MAKE=wsl make" & goto run-make-lint
 echo Could not find GNU Make, needed for linting C/C++
 echo Alternatively, you can use WSL
-goto lint-js
+goto lint-js-build
 
 :run-make-lint
 %NODEJS_MAKE% lint-cpp