helloadhavan/github_issues huggingface dataset:
Repository: vuejs/vue
Pull request: [weex] Expose version and config on subVue

In Weex, the `Vue` variable in each js bundle is generate by `Vue.extend({})` actually, and pass some global properties to it. But forget to expose the `version` and `config` on subVue.

I additionally exposed three props to subVue:

+ `version`
+ `weexVersion`
+ `config`

Some libs, such as `Vuex`, may relay on the `version` and `config`.

Changed files:
filename: src/entries/weex-framework.js
patch: @@ -103,7 +103,7 @@ export function createInstance (
   subVue.options._base = subVue
 
   // expose global utility
-  ;['util', 'set', 'delete', 'nextTick'].forEach(name => {
+  ;['util', 'set', 'delete', 'nextTick', 'version', 'weexVersion', 'config'].forEach(name => {
     subVue[name] = Vue[name]
   })
Repository: electron/electron
Pull request: fix: `systemPreferences.getAccentColor` inverted color

Backport of #48511

See that PR for details.


Notes: Fixed an issue where `systemPreferences.getAccentColor` inverted the color.


Changed files:
filename: shell/browser/api/electron_api_system_preferences_win.cc
patch: @@ -16,6 +16,7 @@
 #include "base/win/wrapped_window_proc.h"
 #include "shell/common/color_util.h"
 #include "shell/common/process_util.h"
+#include "skia/ext/skia_utils_win.h"
 #include "ui/gfx/win/hwnd_util.h"
 #include "ui/gfx/win/singleton_hwnd.h"
 
@@ -88,7 +89,7 @@ std::string SystemPreferences::GetAccentColor() {
   if (!color.has_value())
     return "";
 
-  return hexColorDWORDToRGBA(color.value());
+  return ToRGBAHex(skia::COLORREFToSkColor(color.value()), false);
 }
 
 std::string SystemPreferences::GetColor(gin_helper::ErrorThrower thrower,

filename: spec/api-browser-window-spec.ts
patch: @@ -1,4 +1,4 @@
-import { app, BrowserWindow, BrowserView, dialog, ipcMain, OnBeforeSendHeadersListenerDetails, net, protocol, screen, webContents, webFrameMain, session, WebContents, WebFrameMain } from 'electron/main';
+import { app, BrowserWindow, BrowserView, dialog, ipcMain, OnBeforeSendHeadersListenerDetails, net, protocol, screen, webContents, webFrameMain, session, systemPreferences, WebContents, WebFrameMain } from 'electron/main';
 
 import { expect } from 'chai';
 
@@ -2590,6 +2590,14 @@ describe('BrowserWindow module', () => {
       expect(accentColor).to.match(/^#[0-9A-F]{6}$/i);
     });
 
+    it('matches the systemPreferences system color when true', () => {
+      const w = new BrowserWindow({ show: false });
+      w.setAccentColor(true);
+      const accentColor = w.getAccentColor() as string;
+      const systemColor = systemPreferences.getAccentColor().slice(0, 6);
+      expect(accentColor).to.equal(`#${systemColor}`);
+    });
+
     it('returns the correct accent color after multiple changes', () => {
       const w = new BrowserWindow({ show: false });
Repository: vuejs/vue
Pull request: Node maybe be removed by v-html/v-text (fix #4535)

fix #4535 

relative commit https://github.com/vuejs/vue/commit/d0afcd3cf9ad572621676ef02005d226cb4ac7c4#diff-4c8bbf2657619e18d911574dbc6b32e9

Changed files:
filename: src/core/vdom/patch.js
patch: @@ -69,16 +69,16 @@ export function createPatchFunction (backend) {
   function createRmCb (childElm, listeners) {
     function remove () {
       if (--remove.listeners === 0) {
-        removeElement(childElm)
+        removeNode(childElm)
       }
     }
     remove.listeners = listeners
     return remove
   }
 
-  function removeElement (el) {
+  function removeNode (el) {
     const parent = nodeOps.parentNode(el)
-    // element may have already been removed due to v-html
+    // element may have already been removed due to v-html / v-text
     if (parent) {
       nodeOps.removeChild(parent, el)
     }
@@ -298,7 +298,7 @@ export function createPatchFunction (backend) {
           removeAndInvokeRemoveHook(ch)
           invokeDestroyHook(ch)
         } else { // Text node
-          nodeOps.removeChild(parentElm, ch.elm)
+          removeNode(ch.elm)
         }
       }
     }
@@ -328,7 +328,7 @@ export function createPatchFunction (backend) {
         rm()
       }
     } else {
-      removeElement(vnode.elm)
+      removeNode(vnode.elm)
     }
   }
 

filename: test/unit/modules/vdom/modules/dom-props.spec.js
patch: @@ -52,6 +52,16 @@ describe('vdom domProps module', () => {
     const elm2 = patch(null, vnode2)
     expect(elm2.textContent).toBe('hi')
     expect(vnode2.children.length).toBe(0)
+
+    const vnode3 = new VNode('div', undefined, undefined, '123')
+    patch(null, vnode3)
+    const elm3 = patch(vnode3, vnode2)
+    expect(elm3.textContent).toBe('hi')
+
+    const vnode4 = new VNode('div', undefined, undefined, new VNode('span'))
+    patch(null, vnode4)
+    const elm4 = patch(vnode4, vnode)
+    expect(elm4.textContent).toBe('hi')
   })
 
   it('should handle mutating observed props object', done => {
Repository: ggml-org/llama.cpp
Pull request: completion : simplify batch (embd) processing

This commit simplifies the processing of embd by removing the for loop that currently exists which uses params.n_batch as its increment. This commit also removes the clamping of n_eval as the size of embd is always at most the size of params.n_batch.

The motivation is to clarify the code as it is currently a little confusing when looking at this for loop in isolation and thinking that it can process multiple batches.


Changed files:
filename: tools/completion/completion.cpp
patch: @@ -674,15 +674,12 @@ int main(int argc, char ** argv) {
                 }
             }
 
-            for (int i = 0; i < (int) embd.size(); i += params.n_batch) {
-                int n_eval = (int) embd.size() - i;
-                if (n_eval > params.n_batch) {
-                    n_eval = params.n_batch;
-                }
-
+            if (!embd.empty()) {
+                int n_eval = (int) embd.size();
                 LOG_DBG("eval: %s\n", string_from(ctx, embd).c_str());
 
-                if (llama_decode(ctx, llama_batch_get_one(&embd[i], n_eval))) {
+                GGML_ASSERT(n_eval <= params.n_batch);
+                if (llama_decode(ctx, llama_batch_get_one(embd.data(), n_eval))) {
                     LOG_ERR("%s : failed to eval\n", __func__);
                     return 1;
                 }
@@ -743,7 +740,7 @@ int main(int argc, char ** argv) {
                 common_sampler_accept(smpl, embd_inp[n_consumed], /* accept_grammar= */ false);
 
                 ++n_consumed;
-                if ((int) embd.size() >= params.n_batch) {
+                if ((int) embd.size() == params.n_batch) {
                     break;
                 }
             }
Repository: nodejs/node
Pull request: test: correct conditional secure heap flags test

Refs https://github.com/nodejs/node/pull/58376

When `V8_ENABLE_SANDBOX` is true,  `--secure-heap` and `--secure-heap-min` won't exist in `process.allowedNodeEnvironmentFlags`.
<!--
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: test/parallel/test-process-env-allowed-flags-are-documented.js
patch: @@ -49,6 +49,8 @@ if (!hasOpenSSL3) {
   documented.delete('--openssl-shared-config');
 }
 
+const isV8Sandboxed = process.config.variables.v8_enable_sandbox;
+
 // Filter out options that are conditionally present.
 const conditionalOpts = [
   {
@@ -74,6 +76,9 @@ const conditionalOpts = [
   }, {
     include: process.features.inspector,
     filter: (opt) => opt.startsWith('--inspect') || opt === '--debug-port'
+  }, {
+    include: !isV8Sandboxed,
+    filter: (opt) => ['--secure-heap', '--secure-heap-min'].includes(opt)
   },
 ];
 documented.forEach((opt) => {
Repository: huggingface/transformers
Pull request: [cleanup] Don't use Repository in create_dummy_models.py script

Hopefully last cleanup PR from me before v5 :)

Mentioned as a TODO in https://github.com/huggingface/transformers/pull/40889. This PR updates `create_dummy_models.py` to use `upload_folder` instead of `Repository` class (which doesn't exist anymore).

Changed files:
filename: utils/create_dummy_models.py
patch: @@ -28,7 +28,7 @@
 from check_config_docstrings import get_checkpoint_from_config_class
 from datasets import load_dataset
 from get_test_info import get_model_to_tester_mapping, get_tester_classes_for_model
-from huggingface_hub import Repository, create_repo, hf_api, upload_folder  # TODO: remove Repository
+from huggingface_hub import create_repo, hf_api, upload_folder
 
 from transformers import (
     CONFIG_MAPPING,
@@ -805,30 +805,19 @@ def upload_model(model_dir, organization, token):
     if error is not None:
         raise error
 
-    with tempfile.TemporaryDirectory() as tmpdir:
-        repo = Repository(local_dir=tmpdir, clone_from=repo_id, token=token)
-        repo.git_pull()
-        shutil.copytree(model_dir, tmpdir, dirs_exist_ok=True)
-
-        if repo_exist:
-            # Open a PR on the existing Hub repo.
-            hub_pr_url = upload_folder(
-                folder_path=model_dir,
-                repo_id=repo_id,
-                repo_type="model",
-                commit_message=f"Update tiny models for {arch_name}",
-                commit_description=f"Upload tiny models for {arch_name}",
-                create_pr=True,
-                token=token,
-            )
-            logger.warning(f"PR open in {hub_pr_url}.")
-            # TODO: We need this information?
-        else:
-            # Push to Hub repo directly
-            repo.git_add(auto_lfs_track=True)
-            repo.git_commit(f"Upload tiny models for {arch_name}")
-            repo.git_push(blocking=True)  # this prints a progress bar with the upload
-            logger.warning(f"Tiny models {arch_name} pushed to {repo_id}.")
+    create_pr = repo_exist  # Open a PR on existing repo, otherwise push directly
+    commit = upload_folder(
+        folder_path=model_dir,
+        repo_id=repo_id,
+        repo_type="model",
+        commit_message=f"Update tiny models for {arch_name}",
+        commit_description=f"Upload tiny models for {arch_name}",
+        create_pr=create_pr,
+        token=token,
+    )
+
+    msg = f"PR open in {commit.pr_url}." if create_pr else f"Tiny models {arch_name} pushed to {repo_id}."
+    logger.warning(msg)
 
 
 def build_composite_models(config_class, output_dir):
Repository: electron/electron
Pull request: fix: icon in Windows toast notification

Backport of #48543

See that PR for details.


Notes: Fixed an issue where icons didn't show up as expected on Windows Toast notifications.


Changed files:
filename: shell/browser/notifications/win/notification_presenter_win.cc
patch: @@ -30,9 +30,8 @@ namespace {
 bool SaveIconToPath(const SkBitmap& bitmap, const base::FilePath& path) {
   std::optional<std::vector<uint8_t>> png_data =
       gfx::PNGCodec::EncodeBGRASkBitmap(bitmap, false);
-  if (!png_data.has_value())
+  if (!png_data.has_value() || !png_data.value().size())
     return false;
-
   return base::WriteFile(path, png_data.value());
 }
 
@@ -64,8 +63,10 @@ bool NotificationPresenterWin::Init() {
 std::wstring NotificationPresenterWin::SaveIconToFilesystem(
     const SkBitmap& icon,
     const GURL& origin) {
-  std::string filename;
+  if (icon.drawsNothing())
+    return L"";
 
+  std::string filename;
   if (origin.is_valid()) {
     filename = base::MD5String(origin.spec()) + ".png";
   } else {
@@ -75,11 +76,11 @@ std::wstring NotificationPresenterWin::SaveIconToFilesystem(
 
   ScopedAllowBlockingForElectron allow_blocking;
   base::FilePath path = temp_dir_.GetPath().Append(base::UTF8ToWide(filename));
-  if (base::PathExists(path))
-    return path.value();
-  if (SaveIconToPath(icon, path))
-    return path.value();
-  return base::UTF8ToWide(origin.spec());
+
+  if (!SaveIconToPath(icon, path))
+    return L"";
+
+  return path.value();
 }
 
 Notification* NotificationPresenterWin::CreateNotificationObject(

filename: shell/browser/notifications/win/windows_toast_notification.cc
patch: @@ -302,6 +302,7 @@ std::u16string WindowsToastNotification::GetToastXml(
   // Optional icon as app logo override (small icon).
   if (!icon_path.empty()) {
     xml_writer.StartElement(kImage);
+    xml_writer.AddAttribute(kID, "1");
     xml_writer.AddAttribute(kPlacement, kAppLogoOverride);
     xml_writer.AddAttribute(kHintCrop, kHintCropNone);
     xml_writer.AddAttribute(kSrc, base::WideToUTF8(icon_path));
Repository: facebook/react
Pull request: Permit non-`DEV` Elements in `React.Children` w/ `DEV`

## Summary

As mentioned in https://github.com/facebook/react/pull/29662#discussion_r1913820616, the `key` validation when using `React.Children` does not currently support non-`DEV` elements in `DEV`. This minor fix preserves support for these use cases.

## How did you test this change?

```
$ yarn test ReactChildren-test.js
```

Changed files:
filename: packages/react/src/__tests__/ReactChildren-test.js
patch: @@ -1039,6 +1039,31 @@ describe('ReactChildren', () => {
     });
   });
 
+  it('does not throw on children without `_store`', async () => {
+    function ComponentRenderingFlattenedChildren({children}) {
+      return <div>{React.Children.toArray(children)}</div>;
+    }
+
+    const source = <div />;
+    const productionElement = {};
+    Object.entries(source).forEach(([key, value]) => {
+      if (key !== '_owner' && key !== '_store') {
+        productionElement[key] = value;
+      }
+    });
+    Object.freeze(productionElement);
+
+    const container = document.createElement('div');
+    const root = ReactDOMClient.createRoot(container);
+    await act(() => {
+      root.render(
+        <ComponentRenderingFlattenedChildren>
+          {productionElement}
+        </ComponentRenderingFlattenedChildren>,
+      );
+    });
+  });
+
   it('should escape keys', () => {
     const zero = <div key="1" />;
     const one = <div key="1=::=2" />;

filename: packages/react/src/jsx/ReactJSXElement.js
patch: @@ -813,7 +813,9 @@ export function cloneAndReplaceKey(oldElement, newKey) {
   );
   if (__DEV__) {
     // The cloned element should inherit the original element's key validation.
-    clonedElement._store.validated = oldElement._store.validated;
+    if (oldElement._store) {
+      clonedElement._store.validated = oldElement._store.validated;
+    }
   }
   return clonedElement;
 }
Repository: huggingface/transformers
Pull request: Fix doc builds

Doc builds on main are currently failing with errors in this segment. For simplicity before the launch, I'll just remove the example for now!

Changed files:
filename: src/transformers/models/llama/tokenization_llama.py
patch: @@ -77,15 +77,6 @@ class LlamaTokenizer(TokenizersBackend):
             Whether or not to add an `eos_token` at the end of sequences.
         use_default_system_prompt (`bool`, *optional*, defaults to `False`):
             Whether or not the default system prompt for Llama should be used
-            A simple example:
-            ```python
-    >>> from transformers import LlamaTokenizer
-
-            >>> tokenizer = LlamaTokenizer.from_pretrained("huggyllama/llama-7b")
-            >>> tokenizer.encode("Hello 
.") # 869 is '▁.'
-            [1, 15043, 29871, 1, 869]
-            ```
-            Checkout the [pull request](https://github.com/huggingface/transformers/pull/24565) for more details.
         add_prefix_space (`bool`, *optional*):
             Whether or not the tokenizer should automatically add a prefix space
     """
Repository: nodejs/node
Pull request: deps: update simdjson to 4.1.0

This is an automated update of simdjson to 4.1.0.

Changed files:
filename: deps/simdjson/simdjson.cpp
patch: @@ -1,4 +1,4 @@
-/* auto-generated on 2025-09-29 20:34:35 -0700. version 4.0.7 Do not edit! */
+/* auto-generated on 2025-10-27 16:52:41 -0400. version 4.1.0 Do not edit! */
 /* including simdjson.cpp:  */
 /* begin file simdjson.cpp */
 #define SIMDJSON_SRC_SIMDJSON_CPP
@@ -3030,6 +3030,25 @@ concept container_but_not_string =
   std::ranges::input_range<T> && !string_like<T> && !concepts::string_view_keyed_map<T>;
 
 
+
+// Concept: Indexable container that is not a string or associative container
+// Accepts: std::vector, std::array, std::deque (have operator[], value_type, not string_like)
+// Rejects: std::string (string_like), std::list (no operator[]), std::map (has key_type)
+template<typename Container>
+concept indexable_container = requires {
+  typename Container::value_type;
+  requires !concepts::string_like<Container>;
+  requires !requires { typename Container::key_type; };  // Reject maps/sets
+  requires requires(Container& c, std::size_t i) {
+    { c[i] } -> std::convertible_to<typename Container::value_type>;
+  };
+};
+
+
+// Variable template to use with std::meta::substitute
+template<typename Container>
+constexpr bool indexable_container_v = indexable_container<Container>;
+
 } // namespace concepts
 
 
@@ -5047,7 +5066,8 @@ namespace internal {
     { INCOMPLETE_ARRAY_OR_OBJECT, "INCOMPLETE_ARRAY_OR_OBJECT: JSON document ended early in the middle of an object or array. This is a fatal and unrecoverable error." },
     { SCALAR_DOCUMENT_AS_VALUE, "SCALAR_DOCUMENT_AS_VALUE: A JSON document made of a scalar (number, Boolean, null or string) is treated as a value. Use get_bool(), get_double(), etc. on the document instead. "},
     { OUT_OF_BOUNDS, "OUT_OF_BOUNDS: Attempt to access location outside of document."},
-    { TRAILING_CONTENT, "TRAILING_CONTENT: Unexpected trailing content in the JSON input."}
+    { TRAILING_CONTENT, "TRAILING_CONTENT: Unexpected trailing content in the JSON input."},
+    { OUT_OF_CAPACITY, "OUT_OF_CAPACITY: The capacity was exceeded, we cannot allocate enough memory."}
   }; // error_messages[]
 
 } // namespace internal
Repository: ollama/ollama
Pull request: Only enable numa on CPUs

The numa flag may be having a performance impact on multi-socket systems with GPU loads

Changed files:
filename: llm/server.go
patch: @@ -258,7 +258,7 @@ func NewLlamaServer(gpus gpu.GpuInfoList, model string, ggml *GGML, adapters, pr
 		params = append(params, "--mlock")
 	}
 
-	if gpu.IsNUMA() {
+	if gpu.IsNUMA() && gpus[0].Library == "cpu" {
 		numaMode := "distribute"
 		if runtime.GOOS == "linux" {
 			if _, err := exec.LookPath("numactl"); err == nil {
Repository: facebook/react
Pull request: Fix typo in dangerfile.js which results in an unreachable code path…

## Summary

Fix typo in dangerfile.js which results in an unreachable code path which ought to be hit when there is no matching base artifact during DangerCI automated code review.

See: https://github.com/facebook/react/blob/221f3002caa2314cba0a62950da6fb92b453d1d0/dangerfile.js#L73
Compare: https://github.com/facebook/react/blob/221f3002caa2314cba0a62950da6fb92b453d1d0/dangerfile.js#L171
And the case which should hit this code path: https://github.com/facebook/react/blob/221f3002caa2314cba0a62950da6fb92b453d1d0/dangerfile.js#L160

Given the above context, the condition `Number === Infinity` is clearly meant to be `decimal === Infinity`, which it will be if the `catch` statement triggers when there is no matching base artifact. Without this fix, the primitive value `Infinity` is passed to `percentFormatter.format(decimal)`, resulting in the string `'+∞%'`. With this fix, the resulting string will be the intended `'New file'`.

## [Resolves issue 32278](https://github.com/facebook/react/issues/32278)

Changed files:
filename: dangerfile.js
patch: @@ -70,7 +70,7 @@ const percentFormatter = new Intl.NumberFormat('en', {
 });
 
 function change(decimal) {
-  if (Number === Infinity) {
+  if (decimal === Infinity) {
     return 'New file';
   }
   if (decimal === -1) {
Repository: electron/electron
Pull request: fix: icon in Windows toast notification

Backport of #48543

See that PR for details.


Notes: Fixed an issue where icons didn't show up as expected on Windows Toast notifications.


Changed files:
filename: shell/browser/notifications/win/notification_presenter_win.cc
patch: @@ -30,9 +30,8 @@ namespace {
 bool SaveIconToPath(const SkBitmap& bitmap, const base::FilePath& path) {
   std::optional<std::vector<uint8_t>> png_data =
       gfx::PNGCodec::EncodeBGRASkBitmap(bitmap, false);
-  if (!png_data.has_value())
+  if (!png_data.has_value() || !png_data.value().size())
     return false;
-
   return base::WriteFile(path, png_data.value());
 }
 
@@ -64,8 +63,10 @@ bool NotificationPresenterWin::Init() {
 std::wstring NotificationPresenterWin::SaveIconToFilesystem(
     const SkBitmap& icon,
     const GURL& origin) {
-  std::string filename;
+  if (icon.drawsNothing())
+    return L"";
 
+  std::string filename;
   if (origin.is_valid()) {
     filename = base::MD5String(origin.spec()) + ".png";
   } else {
@@ -75,11 +76,11 @@ std::wstring NotificationPresenterWin::SaveIconToFilesystem(
 
   ScopedAllowBlockingForElectron allow_blocking;
   base::FilePath path = temp_dir_.GetPath().Append(base::UTF8ToWide(filename));
-  if (base::PathExists(path))
-    return path.value();
-  if (SaveIconToPath(icon, path))
-    return path.value();
-  return base::UTF8ToWide(origin.spec());
+
+  if (!SaveIconToPath(icon, path))
+    return L"";
+
+  return path.value();
 }
 
 Notification* NotificationPresenterWin::CreateNotificationObject(

filename: shell/browser/notifications/win/windows_toast_notification.cc
patch: @@ -353,6 +353,7 @@ std::u16string WindowsToastNotification::GetToastXml(
   // Optional icon as app logo override (small icon).
   if (!icon_path.empty()) {
     xml_writer.StartElement(kImage);
+    xml_writer.AddAttribute(kID, "1");
     xml_writer.AddAttribute(kPlacement, kAppLogoOverride);
     xml_writer.AddAttribute(kHintCrop, kHintCropNone);
     xml_writer.AddAttribute(kSrc, base::WideToUTF8(icon_path));