chore: bump node to v24.16.0 (43-x-y)#51865
Conversation
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>
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>
af5deae to
1130b0d
Compare
🤔 |
ckerr
left a comment
There was a problem hiding this comment.
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. |
There was a problem hiding this comment.
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. |
There was a problem hiding this comment.
Nonblocking followup task: this patch is uncontroversial, we should upstream it
| 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 |
| bool enable_source_maps = false; | ||
| bool experimental_addon_modules = false; | ||
| bool experimental_eventsource = false; | ||
| + bool experimental_fetch = true; |
There was a problem hiding this comment.
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 🤷♂️
There was a problem hiding this comment.
@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.
|
Release Notes Persisted
|
Backport of #51749
See that PR for details.
Notes: Updated Node.js to v24.16.0.