Skip to content

chore: bump node to v24.16.0 (43-x-y)#51865

Merged
jkleinsc merged 14 commits into
43-x-yfrom
trop/43-x-y-bp-chore-bump-node-to-v24-16-0-main--1780506480366
Jun 8, 2026
Merged

chore: bump node to v24.16.0 (43-x-y)#51865
jkleinsc merged 14 commits into
43-x-yfrom
trop/43-x-y-bp-chore-bump-node-to-v24-16-0-main--1780506480366

Conversation

@trop

@trop trop Bot commented Jun 3, 2026

Copy link
Copy Markdown
Contributor

Backport of #51749

See that PR for details.

Notes: Updated Node.js to v24.16.0.

trop Bot and others added 6 commits June 3, 2026 17:08
Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Upstream moved the static Object* helpers out of network_agent.cc into
the new src/inspector/inspector_object_utils.{h,cc} and converted the
existing methods to NetworkAgent member functions. Update the patch so
the deprecated v8::Context::GetIsolate() removal applies to the new
member methods that obtain the isolate via env_->isolate().

Ref: nodejs/node#61139

Co-Authored-By: Claude <noreply@anthropic.com>

Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com>
Node.js restored fs patchability in the ESM loader upstream, making
the fix_lazyload_fs_in_esm_loaders_to_apply_asar_patches.patch
obsolete (the patch's exact change is now in lib/internal/modules/
esm/{load,resolve,translators}.js).

Ref: nodejs/node#62835

Co-Authored-By: Claude <noreply@anthropic.com>

Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com>
Co-Authored-By: Claude <noreply@anthropic.com>

Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com>
Upstream removed the experimental_fetch field from EnvironmentOptions,
but Electron's patch still registers --experimental-fetch as a CLI
option bound to that field. Re-add the member so the option compiles.

Ref: nodejs/node#62759

Co-Authored-By: Claude <noreply@anthropic.com>

Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com>
libuv 1.52.1 typed uv_cpu_info_t.model as const char*, but uv__free
takes void*. Electron builds with -Werror,-Wincompatible-pointer-types-
discards-qualifiers, so add a cast. The memory is allocated via strdup
so the cast is safe.

Ref: nodejs/node#61829

Co-Authored-By: Claude <noreply@anthropic.com>

Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com>
@trop trop Bot requested review from a team as code owners June 3, 2026 17:08
@trop trop Bot added 43-x-y backport This is a backport PR semver/patch backwards-compatible bug fixes labels Jun 3, 2026
trop Bot and others added 8 commits June 4, 2026 16:02
Cast int nBuf to size_t when comparing with sizeof(aCopy) so the
bundled sqlite3 amalgamation compiles under -Werror,-Wsign-compare.

Ref: nodejs/node#62699

Co-Authored-By: Claude <noreply@anthropic.com>
third_party/electron_node lives under Chromium's src/, whose package.json
("type": "module") is always an ancestor of the Node.js test tree. Upstream
assumes no package.json sits above the tests, so that ancestor changes how
test files and fixtures resolve their module type: it disables module-syntax
detection (breaking test-compile-cache-typescript-esm) and emits
MODULE_TYPELESS_PACKAGE_JSON warnings that break tests asserting clean stderr
(test-esm-detect-ambiguous, test-esm-import-meta-main-eval,
test-output-coverage-with-mock).

Move src/package.json aside for the duration of the run so the environment
matches upstream exactly, then restore it. The original is kept in a sibling
backup file so an interrupted/killed run self-heals on the next invocation
rather than leaving src/package.json missing.

Ref: Unable to locate reference

Co-Authored-By: Claude <noreply@anthropic.com>

Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com>
New inspector/node headers added in Node.js v24.16.0 were missing from
the auto-generated source list.

Ref: Unable to locate reference

Co-Authored-By: Claude <noreply@anthropic.com>

Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com>
The test copies the Electron binary into a standalone .app bundle and
code-signs it; under parallel suite runs this races with dyld resolving
the Electron Framework rpath and intermittently aborts (SIGABRT). It
passes reliably when run alone. Mark it flaky so flakes don't fail CI.

Ref: Unable to locate reference

Co-Authored-By: Claude <noreply@anthropic.com>

Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com>
setDefaultCACertificates() round-trips the default CA set through
BoringSSL's X509_STORE, which dedups a duplicate-subject root (DigiCert
Global Root CA) that OpenSSL keeps. The set therefore loses one cert on
re-add (149 -> 148), so the test's assertEqualCerts round-trip check
fails under Electron's BoringSSL. The sibling -recovery test is disabled
for the same reason.

Ref: nodejs/node#58822

Co-Authored-By: Claude <noreply@anthropic.com>

Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com>
test-run-watch-repeatedly, test-run-watch-run-duration and
test-run-watch-without-file race under parallel suite load: the watcher
fires an extra re-run before the assertion, so the expected single-run
output ("tests 1") arrives with accumulated subtests. All three pass in
isolation.

Ref: nodejs/node#44898

Co-Authored-By: Claude <noreply@anthropic.com>

Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
Combine the Windows libuv cpu_info const-cast update into the existing
chore_cast_const_away_when_freeing_uv_cpu_info_t_model.patch and keep
a single patch-management commit for the final exported patch series.

Co-Authored-By: Claude <noreply@anthropic.com>

Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
@jkleinsc jkleinsc force-pushed the trop/43-x-y-bp-chore-bump-node-to-v24-16-0-main--1780506480366 branch from af5deae to 1130b0d Compare June 4, 2026 20:03
@ckerr

ckerr commented Jun 8, 2026

Copy link
Copy Markdown
Member

ba1c6cf

Ref: Unable to locate reference

Co-Authored-By: Claude noreply@anthropic.com

🤔

@ckerr ckerr left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I should have looked at this more closely last week when this was PR'ed for main.

I see a handful of followup tasks we should file and also one issue I would have blocked on last week if I'd seen it (the fetch no-op).

Not blocking this PR since it's a trop and the fix will also be a trop. It's on me that I didn't catch this in the main PR. 🤷‍♂️

nBuf to size_t to silence the warning. Callers always pass a
non-negative value so this preserves behavior.

This patch can be removed once sqlite fixes the comparison upstream.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nonblocking followup task: This patch is uncontroversial. We should upstream it

explicitly to drop the const qualifier when freeing. The string was
allocated with strdup() so the cast is safe.

This patch can be removed once libuv fixes the qualifier upstream.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nonblocking followup task: this patch is uncontroversial, we should upstream it

Comment thread patches/node/.patches
build_ensure_native_module_compilation_fails_if_not_using_a_new.patch
fix_expose_the_built-in_electron_module_via_the_esm_loader.patch
enable_crashpad_linux_node_processes.patch
fix_lazyload_fs_in_esm_loaders_to_apply_asar_patches.patch

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉

bool enable_source_maps = false;
bool experimental_addon_modules = false;
bool experimental_eventsource = false;
+ bool experimental_fetch = true;

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I should have caught this last week when the same commit was PR'ed to main, but this seems problematic? We've fixed the compile error, but now we have a new patch that creates a no-op and we still have Electron --experimental-fetch code to poke that no-op.

Upgrades followup task: we should remove this patch and our code that touches EnvironmentOptions::expermental_fetch`

Nonblocking since this is a trop and the same issue is live in main now, so the fix should land in main first & be tropped 🤷‍♂️

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ckerr I thought the same, but I believe we actually do need the patch/its not a no-op because we have to patch node to not make node's fetch available in the renderer, eg
this part of the patch:

+++ b/lib/internal/process/pre_execution.js
@@ -117,6 +117,7 @@ function prepareExecution(options) {
   setupSQLite();
   setupQuic();
   setupWebStorage();
+  setupFetch();
   setupWebsocket();
   setupEventsource();
   setupCodeCoverage();
@@ -350,6 +351,16 @@ function setupWarningHandler() {
   }
 }
 
+function setupFetch() {
+  if (getOptionValue('--no-experimental-fetch')) {
+    delete globalThis.fetch;
+    delete globalThis.FormData;
+    delete globalThis.Headers;
+    delete globalThis.Request;
+    delete globalThis.Response;
+  }
+}
+

And we need a way flag this in node because it doesn't apply from the main process.

@jkleinsc jkleinsc merged commit d1c6030 into 43-x-y Jun 8, 2026
69 checks passed
@release-clerk

release-clerk Bot commented Jun 8, 2026

Copy link
Copy Markdown

Release Notes Persisted

Updated Node.js to v24.16.0.

@jkleinsc jkleinsc deleted the trop/43-x-y-bp-chore-bump-node-to-v24-16-0-main--1780506480366 branch June 8, 2026 17:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

43-x-y backport This is a backport PR semver/patch backwards-compatible bug fixes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants