helloadhavan/github_issues huggingface dataset:
Repository: facebook/react
Pull request: Fix indices of hooks in devtools when using useSyncExternalStore

## Summary

This PR updates getChangedHooksIndices to account for the fact that useSyncExternalStore internally mounts two hooks, while DevTools should treat it as a single user-facing hook.

It introduces a helper isUseSyncExternalStoreHook to detect this case and adjust iteration so the extra internal hook is skipped when counting changes.

Before:

https://github.com/user-attachments/assets/0db72a4e-21f7-44c7-ba02-669a272631e5

After:

https://github.com/user-attachments/assets/4da71392-0396-408d-86a7-6fbc82d8c4f5

## How did you test this change?

I used this component to reproduce this issue locally (I followed instructions in `packages/react-devtools/CONTRIBUTING.md`).

```ts
function Test() {
  // 1
  React.useSyncExternalStore(
    () => {},
    () => {},
    () => {},
  );
  // 2
  const [state, setState] = useState('test'); 
  return (
    <>
      <div
        onClick={() => setState(Math.random())}
        style={{backgroundColor: 'red'}}>
        {state}
      </div>
    </>
  );
}
```


Changed files:
filename: packages/react-devtools-shared/src/backend/fiber/renderer.js
patch: @@ -1913,6 +1913,20 @@ export function attach(
     return false;
   }
 
+  function isUseSyncExternalStoreHook(hookObject: any): boolean {
+    const queue = hookObject.queue;
+    if (!queue) {
+      return false;
+    }
+
+    const boundHasOwnProperty = hasOwnProperty.bind(queue);
+    return (
+      boundHasOwnProperty('value') &&
+      boundHasOwnProperty('getSnapshot') &&
+      typeof queue.getSnapshot === 'function'
+    );
+  }
+
   function isHookThatCanScheduleUpdate(hookObject: any) {
     const queue = hookObject.queue;
     if (!queue) {
@@ -1929,12 +1943,7 @@ export function attach(
       return true;
     }
 
-    // Detect useSyncExternalStore()
-    return (
-      boundHasOwnProperty('value') &&
-      boundHasOwnProperty('getSnapshot') &&
-      typeof queue.getSnapshot === 'function'
-    );
+    return isUseSyncExternalStoreHook(hookObject);
   }
 
   function didStatefulHookChange(prev: any, next: any): boolean {
@@ -1955,10 +1964,18 @@ export function attach(
 
     const indices = [];
     let index = 0;
+
     while (next !== null) {
       if (didStatefulHookChange(prev, next)) {
         indices.push(index);
       }
+
+      // useSyncExternalStore creates 2 internal hooks, but we only count it as 1 user-facing hook
+      if (isUseSyncExternalStoreHook(next)) {
+        next = next.next;
+        prev = prev.next;
+      }
+
       next = next.next;
       prev = prev.next;
       index++;
Repository: nodejs/node
Pull request: src,sqlite: fix filterFunc dangling reference

Fixes #62276

Changed files:
filename: src/node_sqlite.cc
patch: @@ -2157,7 +2157,8 @@ void DatabaseSync::ApplyChangeset(const FunctionCallbackInfo<Value>& args) {
 
       Local<Function> filterFunc = filterValue.As<Function>();
 
-      context.filterCallback = [&](std::string_view item) -> bool {
+      context.filterCallback =
+          [env, db, filterFunc](std::string_view item) -> bool {
         // If there was an error in the previous call to the filter's
         // callback, we skip calling it again.
         if (db->ignore_next_sqlite_error_) {
Repository: ollama/ollama
Pull request: cmd/config: Use envconfig.Host() for base API in launch config packages

Closes: https://github.com/ollama/ollama/issues/13936

Changed files:
filename: cmd/config/claude.go
patch: @@ -6,6 +6,8 @@ import (
 	"os/exec"
 	"path/filepath"
 	"runtime"
+
+	"github.com/ollama/ollama/envconfig"
 )
 
 // Claude implements Runner for Claude Code integration
@@ -50,7 +52,7 @@ func (c *Claude) Run(model string) error {
 	cmd.Stdout = os.Stdout
 	cmd.Stderr = os.Stderr
 	cmd.Env = append(os.Environ(),
-		"ANTHROPIC_BASE_URL=http://localhost:11434",
+		"ANTHROPIC_BASE_URL="+envconfig.Host().String(),
 		"ANTHROPIC_API_KEY=",
 		"ANTHROPIC_AUTH_TOKEN=ollama",
 	)

filename: cmd/config/clawdbot.go
patch: @@ -9,6 +9,8 @@ import (
 	"os/exec"
 	"path/filepath"
 	"strings"
+
+	"github.com/ollama/ollama/envconfig"
 )
 
 type Clawdbot struct{}
@@ -90,7 +92,7 @@ func (c *Clawdbot) Edit(models []string) error {
 		ollama = make(map[string]any)
 	}
 
-	ollama["baseUrl"] = "http://127.0.0.1:11434/v1"
+	ollama["baseUrl"] = envconfig.Host().String() + "/v1"
 	// needed to register provider
 	ollama["apiKey"] = "ollama-local"
 	// TODO(parthsareen): potentially move to responses

filename: cmd/config/droid.go
patch: @@ -7,6 +7,8 @@ import (
 	"os/exec"
 	"path/filepath"
 	"slices"
+
+	"github.com/ollama/ollama/envconfig"
 )
 
 // Droid implements Runner and Editor for Droid integration
@@ -117,7 +119,7 @@ func (d *Droid) Edit(models []string) error {
 		newModels = append(newModels, modelEntry{
 			Model:           model,
 			DisplayName:     model,
-			BaseURL:         "http://localhost:11434/v1",
+			BaseURL:         envconfig.Host().String() + "/v1",
 			APIKey:          "ollama",
 			Provider:        "generic-chat-completion-api",
 			MaxOutputTokens: 64000,

filename: cmd/config/droid_test.go
patch: @@ -218,7 +218,7 @@ func TestDroidEdit(t *testing.T) {
 			}
 		}
 
-		if model["baseUrl"] != "http://localhost:11434/v1" {
+		if model["baseUrl"] != "http://127.0.0.1:11434/v1" {
 			t.Errorf("unexpected baseUrl: %s", model["baseUrl"])
 		}
 		if model["apiKey"] != "ollama" {
@@ -447,7 +447,7 @@ const testDroidSettingsFixture = `{
     {
       "model": "existing-ollama-model",
       "displayName": "existing-ollama-model",
-      "baseUrl": "http://localhost:11434/v1",
+      "baseUrl": "http://127.0.0.1:11434/v1",
       "apiKey": "ollama",
       "provider": "generic-chat-completion-api",
       "maxOutputTokens": 64000,

filename: cmd/config/opencode.go
patch: @@ -9,6 +9,8 @@ import (
 	"path/filepath"
 	"slices"
 	"strings"
+
+	"github.com/ollama/ollama/envconfig"
 )
 
 // OpenCode implements Runner and Editor for OpenCode integration
@@ -88,7 +90,7 @@ func (o *OpenCode) Edit(modelList []string) error {
 			"npm":  "@ai-sdk/openai-compatible",
 			"name": "Ollama (local)",
 			"options": map[string]any{
-				"baseURL": "http://localhost:11434/v1",
+				"baseURL": envconfig.Host().String() + "/v1",
 			},
 		}
 	}
Repository: huggingface/transformers
Pull request: Fix unexpected `position_ids` keys when loading OwlViT models

# What does this PR do?

Older OwlViT checkpoints stored `position_ids` as buffers in the text and vision embedding modules. These tensors are simple integer ranges (0 → max sequence length) and are now recomputed dynamically during initialization.

As a result, when loading models such as `google/owlvit-base-patch32`, the loader reports the following unexpected keys:

* `owlvit.text_model.embeddings.position_ids`
* `owlvit.vision_model.embeddings.position_ids`

These buffers are not required for correct model behavior and can be safely ignored.

This PR suppresses the warnings by adding the corresponding patterns to `_keys_to_ignore_on_load_unexpected` in `OwlViTPreTrainedModel`.

This change does **not affect model performance or weights** and only prevents unnecessary loading warnings when using older checkpoints.

Fixes #44493

## Before submitting

* [x] This PR fixes a bug (unexpected keys warning when loading OwlViT checkpoints).
* [x] Did you read the contributor guideline? Yes.
* [x] Was this discussed/approved via a Github issue or the forum? Yes, discussed in #44493.
* [ ] Did you make sure to update the documentation with your changes? Not required.
* [ ] Did you write any new necessary tests? Not required (warning suppression only).

## Who can review?

@Rocketknight1 
@yonigozlan 


Changed files:
filename: src/transformers/models/owlv2/modeling_owlv2.py
patch: @@ -539,6 +539,10 @@ class Owlv2PreTrainedModel(PreTrainedModel):
         "hidden_states": Owlv2EncoderLayer,
         "attentions": Owlv2Attention,
     }
+    _keys_to_ignore_on_load_unexpected = [
+        r".*text_model\.embeddings\.position_ids",
+        r".*vision_model\.embeddings\.position_ids",
+    ]
 
     @torch.no_grad()
     def _init_weights(self, module: nn.Module):

filename: src/transformers/models/owlvit/modeling_owlvit.py
patch: @@ -526,6 +526,10 @@ class OwlViTPreTrainedModel(PreTrainedModel):
         "hidden_states": OwlViTEncoderLayer,
         "attentions": OwlViTAttention,
     }
+    _keys_to_ignore_on_load_unexpected = [
+        r".*text_model\.embeddings\.position_ids",
+        r".*vision_model\.embeddings\.position_ids",
+    ]
 
     @torch.no_grad()
     def _init_weights(self, module: nn.Module):
Repository: rust-lang/rust
Pull request: Update cargo submodule

<!-- homu-ignore:start -->
*[View all comments](https://triagebot.infra.rust-lang.org/gh-comments/rust-lang/rust/pull/154482)*
<!-- homu-ignore:end -->

11 commits in e84cb639edfea2c42efd563b72a9be0cc5de6523..888f675344eb1cf2308fd53183e667bdd2c58e51
2026-03-21 01:27:07 +0000 to 2026-03-30 16:59:25 +0000
- chore: bump to curl-sys@0.4.87 (rust-lang/cargo#16808)
- fix(resolver): Better match rustc in error styling (rust-lang/cargo#16795)
- missing -Zjson-target-spec error: mention that this is a cargo flag (rust-lang/cargo#16793)
- Update changelog for 1.94.1 (rust-lang/cargo#16789)
- test(build): Make it easier to review `build.warnings` behavior (rust-lang/cargo#16788)
- test(build): Cover more behavior of `build.warnings` (rust-lang/cargo#16785)
- chore(deps): bump curl-sys from 0.4.83 to 0.4.86 (rust-lang/cargo#16786)
- Warn when installing with a non-default toolchain (rust-lang/cargo#16131)
- feat(cli): Add support for completing `--config` argument values with `native-completions` (rust-lang/cargo#16249)
- feat(cli): complete `--config` and `--color` before command (rust-lang/cargo#16780)
- chore(deps): bump rustls-webpki from 0.103.9 to 0.103.10 (rust-lang/cargo#16778)


Changed files:
filename: src/tools/cargo
patch: @@ -1 +1 @@
-Subproject commit e84cb639edfea2c42efd563b72a9be0cc5de6523
+Subproject commit 888f675344eb1cf2308fd53183e667bdd2c58e51
Repository: nodejs/node
Pull request: build: fix timezone-update path references

Path `tools/timezone-update.yml` does not exist.

Changed files:
filename: .github/workflows/timezone-update.yml
patch: @@ -57,7 +57,7 @@ jobs:
         with:
           author: Node.js GitHub Bot <github-bot@iojs.org>
           body: |
-            This PR was generated by tools/timezone-update.yml.
+            This PR was generated by `.github/workflows/timezone-update.yml` and `tools/update-timezone.mjs`.
 
             Updates the ICU files as per the instructions present in https://github.com/nodejs/node/blob/main/doc/contributing/maintaining/maintaining-icu.md#time-zone-data
Repository: facebook/react
Pull request: [test] Add tests for cyclic arrays in Flight and Flight Reply

We already had tests for cyclic objects, but not for cyclic arrays.

Changed files:
filename: packages/react-client/src/__tests__/ReactFlight-test.js
patch: @@ -724,6 +724,25 @@ describe('ReactFlight', () => {
     });
   });
 
+  it('can transport cyclic arrays', async () => {
+    function ComponentClient({prop, obj}) {
+      expect(prop[1]).toBe(prop);
+      expect(prop[0]).toBe(obj);
+    }
+    const Component = clientReference(ComponentClient);
+
+    const obj = {};
+    const cyclic = [obj];
+    cyclic[1] = cyclic;
+    const model = <Component prop={cyclic} obj={obj} />;
+
+    const transport = ReactNoopFlightServer.render(model);
+
+    await act(async () => {
+      ReactNoop.render(await ReactNoopFlightClient.read(transport));
+    });
+  });
+
   it('can render a lazy component as a shared component on the server', async () => {
     function SharedComponent({text}) {
       return (

filename: packages/react-server-dom-webpack/src/__tests__/ReactFlightDOMReply-test.js
patch: @@ -650,6 +650,17 @@ describe('ReactFlightDOMReply', () => {
     expect(root.prop.obj).toBe(root.prop);
   });
 
+  it('can transport cyclic arrays', async () => {
+    const obj = {};
+    const cyclic = [obj];
+    cyclic[1] = cyclic;
+
+    const body = await ReactServerDOMClient.encodeReply({prop: cyclic, obj});
+    const root = await ReactServerDOMServer.decodeReply(body, webpackServerMap);
+    expect(root.prop[1]).toBe(root.prop);
+    expect(root.prop[0]).toBe(root.obj);
+  });
+
   it('can abort an unresolved model and get the partial result', async () => {
     const promise = new Promise(r => {});
     const controller = new AbortController();
Repository: vercel/next.js
Pull request: [test] Resolve stale merge issues

Caused by https://github.com/vercel/next.js/pull/91207 and https://github.com/vercel/next.js/pull/91256/

Changed files:
filename: test/development/app-dir/instant-navs-devtools/instant-navs-devtools.test.ts
patch: @@ -42,14 +42,18 @@ describe('instant-nav-panel', () => {
     return browser.elementByCss('#_next-devtools-panel-close').click()
   }
 
+  async function hasInstantNavPanelOpen(browser: Playwright): Promise<void> {
+    await browser.elementByCssInstant('.instant-nav-panel')
+  }
+
   async function openInstantNavPanel(browser: Playwright) {
     await toggleDevToolsIndicatorPopover(browser)
     await waitForPanelRouterTransition()
     await clickInstantNavMenuItem(browser)
 
     await retry(
       async () => {
-        await browser.elementByCssInstant('.instant-nav-panel')
+        await hasInstantNavPanelOpen(browser)
       },
       5_000,
       500
@@ -158,17 +162,14 @@ describe('instant-nav-panel', () => {
 
     // Open the panel and click Start to set the cookie
     await openInstantNavPanel(browser)
-    await retry(async () => {
-      expect(await hasPanelOpen(browser)).toBe(true)
-    })
     await clickStartClientNav(browser)
 
     // Reload — the cookie persists, so the panel should auto-open
     await browser.refresh()
     await browser.waitForElementByCss('[data-testid="home-title"]')
 
     await retry(async () => {
-      expect(await hasPanelOpen(browser)).toBe(true)
+      await hasInstantNavPanelOpen(browser)
     })
 
     // Clean up
Repository: electron/electron
Pull request: fix: crash in clipboard.readImage() on malformed image data

Backport of #50475

See that PR for details.


Notes: Fixed a crash in `clipboard.readImage()` when the clipboard contains malformed image data.

Changed files:
filename: shell/common/api/electron_api_clipboard.cc
patch: @@ -248,7 +248,11 @@ gfx::Image Clipboard::ReadImage(gin::Arguments* const args) {
           [](std::optional<gfx::Image>* image, base::RepeatingClosure cb,
              const std::vector<uint8_t>& result) {
             SkBitmap bitmap = gfx::PNGCodec::Decode(result);
-            image->emplace(gfx::Image::CreateFrom1xBitmap(bitmap));
+            if (bitmap.isNull()) {
+              image->emplace();
+            } else {
+              image->emplace(gfx::Image::CreateFrom1xBitmap(bitmap));
+            }
             std::move(cb).Run();
           },
           &image, std::move(callback)));
Repository: rust-lang/rust
Pull request: `vec::as_mut_slice()`: use lowercase "isize" in safety comment

To match other references to that type

<!-- homu-ignore:start -->
<!--
If this PR is related to an unstable feature or an otherwise tracked effort,
please link to the relevant tracking issue here. If you don't know of a related
tracking issue or there are none, feel free to ignore this.

This PR will get automatically assigned to a reviewer. In case you would like
a specific user to review your work, you can assign it to them by using

    r? <reviewer name>
-->
<!-- homu-ignore:end -->


Changed files:
filename: library/alloc/src/vec/mod.rs
patch: @@ -1853,7 +1853,7 @@ impl<T, A: Allocator> Vec<T, A> {
         // SAFETY: `slice::from_raw_parts_mut` requires pointee is a contiguous, aligned buffer of
         // size `len` containing properly-initialized `T`s. Data must not be accessed through any
         // other pointer for the returned lifetime. Further, `len * size_of::<T>` <=
-        // `ISIZE::MAX` and allocation does not "wrap" through overflowing memory addresses.
+        // `isize::MAX` and allocation does not "wrap" through overflowing memory addresses.
         //
         // * Vec API guarantees that self.buf:
         //      * contains only properly-initialized items within 0..len
Repository: nodejs/node
Pull request: doc: test and test-only targets do not run linter anymore

`make test` and `make test-only` targets no longer runs linters. This commit updates the inline comments and building doc to reflect reality.

Fixes: https://github.com/nodejs/node/issues/58606


Changed files:
filename: BUILDING.md
patch: @@ -404,11 +404,9 @@ If you are running tests before submitting a pull request, use:
 make -j4 test
 ```
 
-`make -j4 test` does a full check on the codebase, including running linters and
-documentation tests.
+`make -j4 test` does a full check on the codebase, including documentation tests.
 
-To run the linter without running tests, use
-`make lint`/`vcbuild lint`. It will lint JavaScript, C++, and Markdown files.
+To run the linter, use `make lint`/`vcbuild lint`. It will lint JavaScript, C++, and Markdown files.
 
 To fix auto fixable JavaScript linting errors, use `make lint-js-fix`.
 

filename: Makefile
patch: @@ -338,7 +338,7 @@ coverage-run-js: ## Run JavaScript tests with coverage.
 
 .PHONY: test
 # This does not run tests of third-party libraries inside deps.
-test: all ## Run default tests, linters, and build docs.
+test: all ## Run default tests and build docs.
 	$(MAKE) -s tooltest
 	$(MAKE) -s build-addons
 	$(MAKE) -s build-js-native-api-tests
@@ -348,7 +348,7 @@ test: all ## Run default tests, linters, and build docs.
 	$(MAKE) -s jstest
 
 .PHONY: test-only
-test-only: all  ## Run default tests, without linters or building the docs.
+test-only: all  ## Run default tests without building the docs.
 	$(MAKE) build-addons
 	$(MAKE) build-js-native-api-tests
 	$(MAKE) build-node-api-tests
Repository: vercel/next.js
Pull request: re-enable RDC deployment tests

Flag has been re-enabled and is attached to the test team.

Changed files:
filename: test/deploy-tests-manifest.json
patch: @@ -86,13 +86,6 @@
     },
     "test/e2e/middleware-rewrites/test/index.test.ts": {
       "failed": ["Middleware Rewrite should handle catch-all rewrite correctly"]
-    },
-    "test/e2e/app-dir/resume-data-cache/resume-data-cache.test.ts": {
-      "failed": [
-        "resume-data-cache should have consistent data between static and dynamic renders with fetch cache",
-        "resume-data-cache should have consistent data between static and dynamic renders with use cache",
-        "resume-data-cache should use RDC for server action re-renders"
-      ]
     }
   },
   "rules": {
Repository: electron/electron
Pull request: fix: crash in clipboard.readImage() on malformed image data

`gfx::PNGCodec::Decode()` returns a null `SkBitmap` when it cannot decode the clipboard contents as a PNG. Passing that null bitmap to `gfx::Image::CreateFrom1xBitmap()` triggers a crash.

This PR adds a null check and returns an empty `gfx::Image` instead, matching the existing pattern in `shell/common/skia_util.cc`.

Notes: Fixed a crash in `clipboard.readImage()` when the clipboard contains malformed image data.

Changed files:
filename: shell/common/api/electron_api_clipboard.cc
patch: @@ -378,7 +378,11 @@ gfx::Image Clipboard::ReadImage(gin::Arguments* const args) {
           [](std::optional<gfx::Image>* image, base::RepeatingClosure cb,
              const std::vector<uint8_t>& result) {
             SkBitmap bitmap = gfx::PNGCodec::Decode(result);
-            image->emplace(gfx::Image::CreateFrom1xBitmap(bitmap));
+            if (bitmap.isNull()) {
+              image->emplace();
+            } else {
+              image->emplace(gfx::Image::CreateFrom1xBitmap(bitmap));
+            }
             std::move(cb).Run();
           },
           &image, std::move(callback)));
Repository: facebook/react
Pull request: Improve cyclic thenable detection in ReactFlightReplyServer

## Summary

This PR improves cyclic thenable detection in `ReactFlightReplyServer.js`. Fixes #35368.
The previous fix only detected direct self-references (`inspectedValue === chunk`) and relied on the `cycleProtection` counter to eventually bail out of longer cycles. This change keeps the existing MAX_THENABLE_CYCLE_DEPTH ($1000$) `cycleProtection` cap as a hard guardrail and adds a visited set so that we can detect self-cycles and multi-node cycles as soon as any `ReactPromise` is revisited and while still bounding the amount of work we do for deep acyclic chains via `cycleProtection`.

## How did you test this change?

- Ran the existing test suite for the server renderer:

  ```bash
  yarn test react-server
  yarn test --prod react-server
  yarn flow dom-node
  yarn linc
  ```

Changed files:
filename: packages/react-server/src/ReactFlightReplyServer.js
patch: @@ -133,14 +133,20 @@ ReactPromise.prototype.then = function <T>(
         // Recursively check if the value is itself a ReactPromise and if so if it points
         // back to itself. This helps catch recursive thenables early error.
         let cycleProtection = 0;
+        const visited = new Set<typeof ReactPromise>();
         while (inspectedValue instanceof ReactPromise) {
           cycleProtection++;
-          if (inspectedValue === chunk || cycleProtection > 1000) {
+          if (
+            inspectedValue === chunk ||
+            visited.has(inspectedValue) ||
+            cycleProtection > 1000
+          ) {
             if (typeof reject === 'function') {
               reject(new Error('Cannot have cyclic thenables.'));
             }
             return;
           }
+          visited.add(inspectedValue);
           if (inspectedValue.status === INITIALIZED) {
             inspectedValue = inspectedValue.value;
           } else {
Repository: ollama/ollama
Pull request: test: fix tools_test.go for ToolCallFunctionArguments API change

This PR fixes compile error of `tools_test.go`

fixes: #13729 

Changed files:
filename: integration/tools_test.go
patch: @@ -131,7 +131,7 @@ func TestAPIToolCalling(t *testing.T) {
 					t.Errorf("unexpected tool called: got %q want %q", lastToolCall.Function.Name, "get_weather")
 				}
 
-				if _, ok := lastToolCall.Function.Arguments["location"]; !ok {
+				if _, ok := lastToolCall.Function.Arguments.Get("location"); !ok {
 					t.Errorf("expected tool arguments to include 'location', got: %s", lastToolCall.Function.Arguments.String())
 				}
 			case <-ctx.Done():
Repository: electron/electron
Pull request: fix: crash in clipboard.readImage() on malformed image data

Backport of #50475

See that PR for details.


Notes: Fixed a crash in `clipboard.readImage()` when the clipboard contains malformed image data.

Changed files:
filename: shell/common/api/electron_api_clipboard.cc
patch: @@ -378,7 +378,11 @@ gfx::Image Clipboard::ReadImage(gin::Arguments* const args) {
           [](std::optional<gfx::Image>* image, base::RepeatingClosure cb,
              const std::vector<uint8_t>& result) {
             SkBitmap bitmap = gfx::PNGCodec::Decode(result);
-            image->emplace(gfx::Image::CreateFrom1xBitmap(bitmap));
+            if (bitmap.isNull()) {
+              image->emplace();
+            } else {
+              image->emplace(gfx::Image::CreateFrom1xBitmap(bitmap));
+            }
             std::move(cb).Run();
           },
           &image, std::move(callback)));