helloadhavan/github_issues huggingface dataset:
Repository: vercel/next.js
Pull request: [cna] Bump vendored `json-schema-types`

Required for TypeScript 6.0. Older versions of `json-schema-types` ship with TypeScript source instead of declaration files.

Changed files:
filename: pnpm-lock.yaml
patch: @@ -12722,8 +12722,8 @@ packages:
   json-schema-typed@7.0.3:
     resolution: {integrity: sha512-7DE8mpG+/fVw+dTpjbxnx47TaMnDfOI1jwft9g1VybltZCduyRQPJPvc+zzKY9WPHxhPWczyFuYa6I8Mw4iU5A==}
 
-  json-schema-typed@8.0.1:
-    resolution: {integrity: sha512-XQmWYj2Sm4kn4WeTYvmpKEbyPsL7nBsb647c7pMe6l02/yx2+Jfc4dT6UZkEXnIUb5LhD55r2HPsJ1milQ4rDg==}
+  json-schema-typed@8.0.2:
+    resolution: {integrity: sha512-fQhoXdcvc3V28x7C7BMs4P5+kNlgUURe2jmUT1T//oBRMDrqy1QPelJimwZGo7Hg9VPV3EQV5Bnq4hbFy2vetA==}
 
   json-schema@0.2.3:
     resolution: {integrity: sha512-a3xHnILGMtk+hDOqNwHzF6e2fNbiMrXZvxKQiEv2MlgQP+pjIOzqAmKYD2mDpXYE/44M7g+n9p2bKkYWDUcXCQ==}
@@ -26686,7 +26686,7 @@ snapshots:
       debounce-fn: 6.0.0
       dot-prop: 9.0.0
       env-paths: 3.0.0
-      json-schema-typed: 8.0.1
+      json-schema-typed: 8.0.2
       semver: 7.6.3
       uint8array-extras: 1.1.0
 
@@ -32010,7 +32010,7 @@ snapshots:
 
   json-schema-typed@7.0.3: {}
 
-  json-schema-typed@8.0.1: {}
+  json-schema-typed@8.0.2: {}
 
   json-schema@0.2.3: {}
Repository: ollama/ollama
Pull request: `/api/show`: default to empty model_info

For `/api/show`, a fully missing `model_info` field trips up various integrators (including a recent Android Studio integration).

The primary source of missing info tends to come from models with a remote that are also missing other data. It seems better to me to return an empty `model_info` than making up some other fields within `model_info` (like saying the architecture is `remote` or something like that). So this does slightly change `/api/show`'s behavior that possibly someone is relying on, but it seems more important to ensure the field is always there (from a quick sampling integrations seem to be robust to missing fields _within_ it).

Fixes: https://github.com/ollama/ollama/issues/13783

Changed files:
filename: api/types.go
patch: @@ -749,7 +749,7 @@ type ShowResponse struct {
 	Messages      []Message          `json:"messages,omitempty"`
 	RemoteModel   string             `json:"remote_model,omitempty"`
 	RemoteHost    string             `json:"remote_host,omitempty"`
-	ModelInfo     map[string]any     `json:"model_info,omitempty"`
+	ModelInfo     map[string]any     `json:"model_info"`
 	ProjectorInfo map[string]any     `json:"projector_info,omitempty"`
 	Tensors       []Tensor           `json:"tensors,omitempty"`
 	Capabilities  []model.Capability `json:"capabilities,omitempty"`

filename: server/routes.go
patch: @@ -1149,6 +1149,9 @@ func GetModelInfo(req api.ShowRequest) (*api.ShowResponse, error) {
 		Capabilities: m.Capabilities(),
 		ModifiedAt:   manifest.fi.ModTime(),
 		Requires:     m.Config.Requires,
+		// Several integrations crash on a nil/omitempty+empty ModelInfo, so by
+		// default we return an empty map.
+		ModelInfo: make(map[string]any),
 	}
 
 	if m.Config.RemoteHost != "" {
Repository: ollama/ollama
Pull request: server: prevent image generation models from reloading on every request

The loadImageGen function was not setting Options on the runnerRef, causing needsReload() to always return true (since it checks if runner.Options == nil). This resulted in the image generation subprocess being killed and restarted for every request.

Changed files:
filename: server/sched.go
patch: @@ -571,6 +571,7 @@ func (s *Scheduler) loadImageGen(req *LlmRequest) bool {
 		model:           req.model,
 		modelPath:       req.model.ModelPath,
 		llama:           server,
+		Options:         &req.opts,
 		loading:         false,
 		sessionDuration: sessionDuration,
 		totalSize:       server.TotalSize(),
Repository: vercel/next.js
Pull request: [Instant] fix instant config suggested by editor plugin

We forgot to update the autocomplete hint when we changed it from `mode` to `prefetch`.

Changed files:
filename: packages/next/src/server/typescript/rules/config.ts
patch: @@ -154,7 +154,7 @@ const API_DOCS: Record<
     // with the way this plugin is currently structured.
     // For now, since we don't provide an `options` here, we won't do any validation in
     // `getSemanticDiagnosticsForExportVariableStatement` below, and only provide hover a tooltip + autocomplete.
-    insertText: 'unstable_instant = { mode: "static" };',
+    insertText: 'unstable_instant = { prefetch: "static" };',
   },
 }
Repository: electron/electron
Pull request: fix: deprecate ELECTRON_SKIP_BINARY_DOWNLOAD env

Backport of #50406

See that PR for details.


Notes: Removed support for the ELECTRON_SKIP_BINARY_DOWNLOAD environment variable.


Changed files:
filename: docs/breaking-changes.md
patch: @@ -70,6 +70,9 @@ npm install electron --save-dev
 ELECTRON_INSTALL_PLATFORM=mas npx electron . --no
 ```
 
+This also means the `ELECTRON_SKIP_BINARY_DOWNLOAD` environment variable is no
+longer supported, as its primary purpose was to prevent the `postinstall` script from running.
+
 ### Removed: `quotas` object from `Session.clearStorageData(options)`
 
 When calling `Session.clearStorageData(options)`, the `options.quotas` object is no longer supported because it has been

filename: docs/tutorial/installation.md
patch: @@ -25,16 +25,6 @@ included in the `electron` package:
 npx install-electron --no
 ```
 
-If you want to install your project's dependencies but don't need to use
-Electron functionality, you can set the `ELECTRON_SKIP_BINARY_DOWNLOAD` environment
-variable to prevent the binary from being downloaded. For instance, this feature can
-be useful in continuous integration environments when running unit tests that mock
-out the `electron` module.
-
-```sh
-ELECTRON_SKIP_BINARY_DOWNLOAD=1 npm install
-```
-
 ## Running Electron ad-hoc
 
 If you're in a pinch and would prefer to not use `npm install` in your local

filename: npm/install.js
patch: @@ -11,10 +11,6 @@ const path = require('path');
 
 const { version } = require('./package');
 
-if (process.env.ELECTRON_SKIP_BINARY_DOWNLOAD) {
-  process.exit(0);
-}
-
 const platformPath = getPlatformPath();
 
 if (isInstalled()) {
Repository: facebook/react
Pull request: fix[devtools]: no-op unsupported backend bridge events

Follow-up to https://github.com/facebook/react/pull/34641.
Similar to https://github.com/facebook/react/pull/35293, https://github.com/facebook/react/pull/35294.

React DevTools backend can be used in non-DOM environments, so we have to feature-check some DOM APIs.
For now I am just no-oping newly added commands for Native, we should revisit this decision once we would roll out Suspense panel there, if needed. I am not sure if scrolling will be required as much as it is needed on Web.

`isReactNativeEnvironment()` check is kinda clowny, but we've been relying on it for quite some time already.

Changed files:
filename: packages/react-devtools-shared/src/backend/views/Highlighter/index.js
patch: @@ -9,6 +9,7 @@
 
 import Agent from 'react-devtools-shared/src/backend/agent';
 import {hideOverlay, showOverlay} from './Highlighter';
+import {isReactNativeEnvironment} from 'react-devtools-shared/src/backend/utils';
 
 import type {HostInstance} from 'react-devtools-shared/src/backend/types';
 import type {BackendBridge} from 'react-devtools-shared/src/bridge';
@@ -49,6 +50,11 @@ export default function setupHighlighter(
     right: number,
     bottom: number,
   }) {
+    if (isReactNativeEnvironment()) {
+      // Not implemented.
+      return;
+    }
+
     if (
       left === Math.round(window.scrollX) &&
       top === Math.round(window.scrollY)
@@ -65,6 +71,11 @@ export default function setupHighlighter(
 
   let scrollTimer = null;
   function sendScroll() {
+    if (isReactNativeEnvironment()) {
+      // Not implemented.
+      return;
+    }
+
     if (scrollTimer) {
       clearTimeout(scrollTimer);
       scrollTimer = null;
@@ -85,14 +96,17 @@ export default function setupHighlighter(
     applyingScroll = false;
   }
 
-  document.addEventListener('scroll', () => {
-    if (!scrollTimer) {
-      // Periodically synchronize the scroll while scrolling.
-      scrollTimer = setTimeout(sendScroll, 400);
-    }
-  });
+  // $FlowFixMe[method-unbinding]
+  if (document && typeof document.addEventListener === 'function') {
+    document.addEventListener('scroll', () => {
+      if (!scrollTimer) {
+        // Periodically synchronize the scroll while scrolling.
+        scrollTimer = setTimeout(sendScroll, 400);
+      }
+    });
 
-  document.addEventListener('scrollend', scrollEnd);
+    document.addEventListener('scrollend', scrollEnd);
+  }
 
   function startInspectingHost(onlySuspenseNodes: boolean) {
     inspectOnlySuspenseNodes = onlySuspenseNodes;
@@ -319,6 +333,11 @@ export default function setupHighlighter(
     // with the scrollIntoView option.
     hideOverlay(agent);
 
+    if (isReactNativeEnvironment()) {
+      // Not implemented.
+      return;
+    }
+
     if (scrollDelayTimer) {
       clearTimeout(scrollDelayTimer);
       scrollDelayTimer = null;
Repository: rust-lang/rust
Pull request: bootstrap: `-Zjson-target-spec` for synthetic targets

Fixes rust-lang/rust#154340

Synthetic targets for mir-opt tests build a standard library using a `.json` target, which now requires `-Zjson-target-spec`

r? @jieyouxu 

Changed files:
filename: src/bootstrap/src/core/builder/cargo.rs
patch: @@ -122,6 +122,9 @@ impl Cargo {
         cmd_kind: Kind,
     ) -> Cargo {
         let mut cargo = builder.cargo(compiler, mode, source_type, target, cmd_kind);
+        if target.synthetic {
+            cargo.arg("-Zjson-target-spec");
+        }
 
         match cmd_kind {
             // No need to configure the target linker for these command types.
@@ -165,7 +168,11 @@ impl Cargo {
         target: TargetSelection,
         cmd_kind: Kind,
     ) -> Cargo {
-        builder.cargo(compiler, mode, source_type, target, cmd_kind)
+        let mut cargo = builder.cargo(compiler, mode, source_type, target, cmd_kind);
+        if target.synthetic {
+            cargo.arg("-Zjson-target-spec");
+        }
+        cargo
     }
 
     pub fn rustdocflag(&mut self, arg: &str) -> &mut Cargo {
Repository: facebook/react
Pull request: [Flight] Never parse "then" functions

AFAIK this is not needed to prevent any exploit but we don't really need this. We allow functions on pretty much any other object anyway but never on the "then" property since those would be serialized as Promises by the client anyway.

Changed files:
filename: packages/react-server/src/ReactFlightReplyServer.js
patch: @@ -437,6 +437,11 @@ function loadServerReference<A: Iterable<any>, T>(
   if (typeof id !== 'string') {
     return (null: any);
   }
+  if (key === 'then') {
+    // This should never happen because we always serialize objects with then-functions
+    // as "thenable" which reduces to ReactPromise with no other fields.
+    return (null: any);
+  }
   const serverReference: ServerReference<T> =
     resolveServerReference<$FlowFixMe>(response._bundlerConfig, id);
   // We expect most servers to not really need this because you'd just have all
@@ -976,7 +981,17 @@ function extractIterator(response: Response, model: Array<any>): Iterator<any> {
   return model[Symbol.iterator]();
 }
 
-function createModel(response: Response, model: any): any {
+function createModel(
+  response: Response,
+  model: any,
+  parentObject: Object,
+  key: string,
+): any {
+  if (key === 'then' && typeof model === 'function') {
+    // This should never happen because we always serialize objects with then-functions
+    // as "thenable" which reduces to ReactPromise with no other fields.
+    return null;
+  }
   return model;
 }
Repository: vercel/next.js
Pull request: Remove sequential madvise for compressed blocks in StaticSortedFile

## Summary

Remove the per-block `madvise(MADV_SEQUENTIAL)` call before decompression in `StaticSortedFile`.

The primary motivation is that the kernel splits mmap regions internally when they receive different `madvise` hints. Each per-block `MADV_SEQUENTIAL` call fragments the VMA (Virtual Memory Area) for the file mapping. For larger builds with many compressed blocks, this causes the process to hit the `vm.max_map_count` limit, leading to failures.

Additionally, the file-level `MADV_RANDOM` advice is sufficient on its own — the sequential hint for individual compressed blocks adds syscall overhead without meaningful benefit, since the decompressor already performs a linear scan in userspace and the blocks are already mapped in memory.

## Changes

- Removed the `madvise(Sequential)` call in `StaticSortedFile::get_block()` for compressed blocks (`turbopack/crates/turbo-persistence/src/static_sorted_file.rs`)

## Test Plan

- Existing turbo-persistence tests continue to pass
- This is a performance-only change with no functional impact

Changed files:
filename: turbopack/crates/turbo-persistence/src/static_sorted_file.rs
patch: @@ -541,17 +541,6 @@ impl StaticSortedFile {
             return Ok(self.mmap_slice_to_arc_bytes(block));
         }
 
-        // Advise Sequential only here: we're about to linearly scan the block
-        // through the decompressor. For uncompressed blocks (returned above)
-        // and lazy medium values (which call get_raw_block directly without
-        // decompressing), the file-level Random advice applies.
-        #[cfg(unix)]
-        let _ = self.mmap.advise_range(
-            memmap2::Advice::Sequential,
-            block.as_ptr() as usize - self.mmap.as_ptr() as usize,
-            block.len(),
-        );
-
         let buffer = decompress_into_arc(uncompressed_length, block).with_context(|| {
             format!(
                 "Failed to decompress block {} from {:08}.sst ({} bytes uncompressed)",
Repository: nodejs/node
Pull request: esm: fix path normalization in `finalizeResolution`

Refs: https://github.com/nodejs/node/pull/61478/changes/BASE..6cd90e1c0167f94c7dc671d10316e561c81f26af#r2871221559


<!--
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: lib/internal/modules/esm/resolve.js
patch: @@ -245,7 +245,7 @@ function finalizeResolution(resolved, base, preserveSymlinks) {
   }
 
   const stats = internalFsBinding.internalModuleStat(
-    StringPrototypeEndsWith(internalFsBinding, path, '/') ? StringPrototypeSlice(path, -1) : path,
+    StringPrototypeEndsWith(path, '/') ? StringPrototypeSlice(path, -1) : path,
   );
 
   // Check for stats.isDirectory()
Repository: huggingface/transformers
Pull request: fix: sig lip import

# What does this PR do?

Fixes the siglip import. that was also crashing the test fetcher

Changed files:
filename: .circleci/config.yml
patch: @@ -46,7 +46,7 @@ jobs:
             - run: uv pip install -U -e .
             - run: echo 'export "GIT_COMMIT_MESSAGE=$(git show -s --format=%s)"' >> "$BASH_ENV" && source "$BASH_ENV"
             - run: mkdir -p test_preparation
-            - run: python utils/tests_fetcher.py | tee tests_fetched_summary.txt || true
+            - run: python utils/tests_fetcher.py | tee tests_fetched_summary.txt
             - run: python utils/tests_fetcher.py --filter_tests || true
             - run: export "GIT_COMMIT_MESSAGE=$(git show -s --format=%s)" && echo $GIT_COMMIT_MESSAGE && python .circleci/create_circleci_config.py --fetcher_folder test_preparation
             - run: |

filename: src/transformers/models/pi0/image_processing_pi0_fast.py
patch: @@ -17,12 +17,20 @@
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and
 # limitations under the License.
-from ...siglip.image_processor_siglip import SiglipImageProcessorFast
+from ...image_processing_utils_fast import BaseImageProcessorFast
+from ...image_utils import IMAGENET_STANDARD_MEAN, IMAGENET_STANDARD_STD, PILImageResampling
 from ...utils import auto_docstring
 
 
 @auto_docstring
-class PI0ImageProcessorFast(SiglipImageProcessorFast):
+class PI0ImageProcessorFast(BaseImageProcessorFast):
+    resample = PILImageResampling.BICUBIC
+    image_mean = IMAGENET_STANDARD_MEAN
+    image_std = IMAGENET_STANDARD_STD
     size = {"max_height": 224, "max_width": 224}
+    default_to_square = False
+    do_resize = True
+    do_rescale = True
+    do_normalize = True
     pad_size = {"height": 224, "width": 224}
     do_pad = True

filename: src/transformers/models/pi0/modular_pi0.py
patch: @@ -31,12 +31,12 @@
 from ...modeling_outputs import BaseModelOutputWithPast, CausalLMOutputWithPast
 from ...modeling_utils import PreTrainedModel
 from ...processing_utils import ProcessingKwargs, Unpack
-from ...siglip.image_processor_siglip import SiglipImageProcessorFast
 from ...tokenization_utils_base import PreTokenizedInput, TextInput
 from ...utils import auto_docstring, can_return_tuple, logging
 from ...utils.generic import maybe_autocast
 from ..auto import CONFIG_MAPPING, AutoConfig, AutoModel
 from ..paligemma.processing_paligemma import PaligemmaProcessor
+from ..siglip.image_processing_siglip_fast import SiglipImageProcessorFast
 
 
 logger = logging.get_logger(__name__)
Repository: rust-lang/rust
Pull request: `trim_prefix` for paths

under rust-lang/rust#142312? 

its a useful method.

Changed files:
filename: library/std/src/path.rs
patch: @@ -2725,6 +2725,41 @@ impl Path {
         self._strip_prefix(base.as_ref())
     }
 
+    /// Returns a path with the optional prefix removed.
+    ///
+    /// If `base` is not a prefix of `self` (i.e., [`starts_with`] returns `false`), returns the original path (`self`)
+    ///
+    /// [`starts_with`]: Path::starts_with
+    ///
+    /// # Examples
+    ///
+    /// ```
+    /// #![feature(trim_prefix_suffix)]
+    /// use std::path::Path;
+    ///
+    /// let path = Path::new("/test/haha/foo.txt");
+    ///
+    /// // Prefix present - remove it
+    /// assert_eq!(path.trim_prefix("/"), Path::new("test/haha/foo.txt"));
+    /// assert_eq!(path.trim_prefix("/test"), Path::new("haha/foo.txt"));
+    /// assert_eq!(path.trim_prefix("/test/"), Path::new("haha/foo.txt"));
+    /// assert_eq!(path.trim_prefix("/test/haha/foo.txt"), Path::new(""));
+    /// assert_eq!(path.trim_prefix("/test/haha/foo.txt/"), Path::new(""));
+    ///
+    /// // Prefix absent - return original
+    /// assert_eq!(path.trim_prefix("test"), path);
+    /// assert_eq!(path.trim_prefix("/te"), path);
+    /// assert_eq!(path.trim_prefix("/haha"), path);
+    /// ```
+    #[must_use = "this returns the remaining path as a new path, without modifying the original"]
+    #[unstable(feature = "trim_prefix_suffix", issue = "142312")]
+    pub fn trim_prefix<P>(&self, base: P) -> &Path
+    where
+        P: AsRef<Path>,
+    {
+        self._strip_prefix(base.as_ref()).unwrap_or(self)
+    }
+
     fn _strip_prefix(&self, base: &Path) -> Result<&Path, StripPrefixError> {
         iter_after(self.components(), base.components())
             .map(|c| c.as_path())
Repository: facebook/react
Pull request: [react-dom/server] Fix hanging on Deno

Reopen of https://github.com/facebook/react/pull/30655

Fixes https://github.com/facebook/react/issues/35231
Closes https://github.com/facebook/react/pull/35247

Changed files:
filename: packages/react-dom/package.json
patch: @@ -61,7 +61,7 @@
       "react-server": "./server.react-server.js",
       "workerd": "./server.edge.js",
       "bun": "./server.bun.js",
-      "deno": "./server.browser.js",
+      "deno": "./server.node.js",
       "worker": "./server.browser.js",
       "node": "./server.node.js",
       "edge-light": "./server.edge.js",
Repository: ollama/ollama
Pull request: app: allow macOS app to terminate during system shutdown

On macOS, users would see "Some updates could not be installed because
`ollama` interrupted restarts" because the app was blocking system
  shutdown/restart requests.

The app's `applicationShouldTerminate`: always returned NSTerminateCancel
to hide to the menu bar instead of quitting. This also blocked macOS
system events like shutdown, restart, and logout.

Fix by listening for NSWorkspaceWillPowerOffNotification and allowing
termination when the system is shutting down, while still hiding to
menu bar for user-initiated quit (Cmd+Q).

Changed files:
filename: app/cmd/app/app_darwin.m
patch: @@ -14,6 +14,7 @@
 @interface AppDelegate () <NSWindowDelegate, WKNavigationDelegate, WKUIDelegate>
 @property(strong, nonatomic) NSStatusItem *statusItem;
 @property(assign, nonatomic) BOOL updateAvailable;
+@property(assign, nonatomic) BOOL systemShutdownInProgress;
 @end
 
 @implementation AppDelegate
@@ -40,6 +41,13 @@ - (void)application:(NSApplication *)application openURLs:(NSArray<NSURL *> *)ur
 }
 
 - (void)applicationDidFinishLaunching:(NSNotification *)aNotification {
+    // Register for system shutdown/restart notification so we can allow termination
+    [[[NSWorkspace sharedWorkspace] notificationCenter]
+        addObserver:self
+           selector:@selector(systemWillPowerOff:)
+               name:NSWorkspaceWillPowerOffNotification
+             object:nil];
+
     // if we're in development mode, set the app icon
     NSString *bundlePath = [[NSBundle mainBundle] bundlePath];
     if (![bundlePath hasSuffix:@".app"]) {
@@ -278,7 +286,18 @@ - (void)startUpdate {
     [NSApp activateIgnoringOtherApps:YES];
 }
 
+- (void)systemWillPowerOff:(NSNotification *)notification {
+    // Set flag so applicationShouldTerminate: knows to allow termination.
+    // The system will call applicationShouldTerminate: after posting this notification.
+    self.systemShutdownInProgress = YES;
+}
+
 - (NSApplicationTerminateReply)applicationShouldTerminate:(NSApplication *)sender {
+    // Allow termination if the system is shutting down or restarting
+    if (self.systemShutdownInProgress) {
+        return NSTerminateNow;
+    }
+    // Otherwise just hide the app (for Cmd+Q, close button, etc.)
     [NSApp hide:nil];
     [NSApp setActivationPolicy:NSApplicationActivationPolicyAccessory];
     return NSTerminateCancel;