Anna Henningsen
6cda3d30c0
src: remove unnecessary c_str() conversions in diagnostic messages
...
PR-URL: https://github.com/nodejs/node/pull/61786
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Edy Silva <edigleyssonsilva@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
2026-04-08 23:53:04 +02:00
Martin Slota
1c2064c1f8
http: fix keep-alive socket reuse race in requestOnFinish
...
When the HTTP response ends before the request's 'finish' event fires,
responseOnEnd() and requestOnFinish() can both call responseKeepAlive(),
corrupting the socket that the agent may have already handed to another
request.
This commit adds a !req.destroyed guard to requestOnFinish() so the
second call is skipped when the socket has already been released.
Fixes: https://github.com/nodejs/node/issues/60001
PR-URL: https://github.com/nodejs/node/pull/61710
Reviewed-By: Tim Perry <pimterry@gmail.com >
2026-04-08 23:53:04 +02:00
deeeb22e1a
worker: eliminate race condition in process.cwd()
...
Fixes a race condition in worker thread cwd caching where the counter
is incremented before the directory change completes, allowing workers
to cache stale directory values.
In lib/internal/worker.js, the main thread's process.chdir() wrapper
previously incremented the shared counter before calling the actual
chdir(), creating a race window where workers could read the old
directory but cache it with the new counter value. This caused
subsequent cwd() calls to return incorrect paths until the next chdir().
This fix reorders the operations to change the directory first, then
increment the counter, ensuring workers are only notified after the
directory change completes.
Before fix: 54.28% error rate (311/573 races)
After fix: 0% error rate (0/832 races)
Refs: https://hackerone.com/reports/3407207
Co-authored-by: Giulio Comi
Co-authored-by: Caleb Everett
Co-authored-by: Utku Yildirim
PR-URL: https://github.com/nodejs/node/pull/61664
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: René <contact.9a5d6388@renegade334.me.uk >
2026-04-08 23:53:04 +02:00
Shelley Vohr
9ad02065d5
test: adapt buffer test for v8 sandbox
...
PR-URL: https://github.com/nodejs/node/pull/61772
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: René <contact.9a5d6388@renegade334.me.uk >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Richard Lau <richard.lau@ibm.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-04-08 23:53:04 +02:00
Andy Weiss
a9c5bd29c9
zlib: add support for brotli compression dictionary
...
This change adds JS API support for custom compression dictionaries
with Brotli in the zlib library. The underlying Brotli dependency
already supports this and zstd exposes something similar.
This follows the zstd approach for using a custom dictionary but
for Brotli.
Fixes: https://github.com/nodejs/node/issues/52250
PR-URL: https://github.com/nodejs/node/pull/61763
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Gürgün Dayıoğlu <hey@gurgun.day >
2026-04-08 23:53:04 +02:00
Ms2ger
5cf001736e
test: update FileAPI tests from WPT
...
PR-URL: https://github.com/nodejs/node/pull/61750
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-04-08 23:53:04 +02:00
Moshe Atlow
207ba4f89f
test_runner: fix suite rerun
...
PR-URL: https://github.com/nodejs/node/pull/61775
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
Reviewed-By: Pietro Marchini <pietro.marchini94@gmail.com >
2026-04-08 23:53:04 +02:00
Tobias Nießen
26c6045363
src: use bool literals in TraceEnvVarOptions
...
The bit fields are declared as `bool` fields, yet are assigned integer
values.
PR-URL: https://github.com/nodejs/node/pull/61425
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2026-04-08 23:53:04 +02:00
René
a810f5ccef
doc: clarify async caveats for events.once()
...
PR-URL: https://github.com/nodejs/node/pull/61572
Refs: https://github.com/nodejs/node/pull/34220
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-04-08 23:53:03 +02:00
Anna Henningsen
72aad8b40f
crypto: always return certificate serial numbers as uppercase
...
This hides a discrepancy between OpenSSL and BoringSSL, as
the latter returns lowercase hex values.
Refs: https://github.com/nodejs/node/pull/61459#discussion_r2713110952
PR-URL: https://github.com/nodejs/node/pull/61752
Reviewed-By: Shelley Vohr <shelley.vohr@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Tim Perry <pimterry@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-04-08 23:53:03 +02:00
dependabot[bot]
00df3c1273
tools: bump unist-util-visit in /tools/doc in the doc group
...
Bumps the doc group in /tools/doc with 1 update: [unist-util-visit](https://github.com/syntax-tree/unist-util-visit ).
Updates `unist-util-visit` from 5.0.0 to 5.1.0
- [Release notes](https://github.com/syntax-tree/unist-util-visit/releases )
- [Commits](https://github.com/syntax-tree/unist-util-visit/compare/5.0.0...5.1.0 )
---
updated-dependencies:
- dependency-name: unist-util-visit
dependency-version: 5.1.0
dependency-type: direct:development
update-type: version-update:semver-minor
dependency-group: doc
...
Signed-off-by: dependabot[bot] <support@github.com >
PR-URL: https://github.com/nodejs/node/pull/61646
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-04-08 23:53:03 +02:00
dependabot[bot]
fe15b0d65e
tools: bump the eslint group in /tools/eslint with 6 updates
...
Bumps the eslint group in /tools/eslint with 6 updates:
| Package | From | To |
| --- | --- | --- |
| [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core ) | `7.28.5` | `7.28.6` |
| [@babel/eslint-parser](https://github.com/babel/babel/tree/HEAD/eslint/babel-eslint-parser ) | `7.28.5` | `7.28.6` |
| [@babel/plugin-syntax-import-source](https://github.com/babel/babel/tree/HEAD/packages/babel-plugin-syntax-import-source ) | `7.27.1` | `7.28.6` |
| [@stylistic/eslint-plugin](https://github.com/eslint-stylistic/eslint-stylistic/tree/HEAD/packages/eslint-plugin ) | `5.6.1` | `5.7.1` |
| [eslint-plugin-jsdoc](https://github.com/gajus/eslint-plugin-jsdoc ) | `61.5.0` | `62.4.1` |
| [globals](https://github.com/sindresorhus/globals ) | `16.5.0` | `17.2.0` |
Updates `@babel/core` from 7.28.5 to 7.28.6
- [Release notes](https://github.com/babel/babel/releases )
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md )
- [Commits](https://github.com/babel/babel/commits/v7.28.6/packages/babel-core )
Updates `@babel/eslint-parser` from 7.28.5 to 7.28.6
- [Release notes](https://github.com/babel/babel/releases )
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md )
- [Commits](https://github.com/babel/babel/commits/v7.28.6/eslint/babel-eslint-parser )
Updates `@babel/plugin-syntax-import-source` from 7.27.1 to 7.28.6
- [Release notes](https://github.com/babel/babel/releases )
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md )
- [Commits](https://github.com/babel/babel/commits/v7.28.6/packages/babel-plugin-syntax-import-source )
Updates `@stylistic/eslint-plugin` from 5.6.1 to 5.7.1
- [Release notes](https://github.com/eslint-stylistic/eslint-stylistic/releases )
- [Changelog](https://github.com/eslint-stylistic/eslint-stylistic/blob/main/CHANGELOG.md )
- [Commits](https://github.com/eslint-stylistic/eslint-stylistic/commits/v5.7.1/packages/eslint-plugin )
Updates `eslint-plugin-jsdoc` from 61.5.0 to 62.4.1
- [Release notes](https://github.com/gajus/eslint-plugin-jsdoc/releases )
- [Commits](https://github.com/gajus/eslint-plugin-jsdoc/compare/v61.5.0...v62.4.1 )
Updates `globals` from 16.5.0 to 17.2.0
- [Release notes](https://github.com/sindresorhus/globals/releases )
- [Commits](https://github.com/sindresorhus/globals/compare/v16.5.0...v17.2.0 )
---
updated-dependencies:
- dependency-name: "@babel/core"
dependency-version: 7.28.6
dependency-type: direct:production
update-type: version-update:semver-patch
dependency-group: eslint
- dependency-name: "@babel/eslint-parser"
dependency-version: 7.28.6
dependency-type: direct:production
update-type: version-update:semver-patch
dependency-group: eslint
- dependency-name: "@babel/plugin-syntax-import-source"
dependency-version: 7.28.6
dependency-type: direct:production
update-type: version-update:semver-minor
dependency-group: eslint
- dependency-name: "@stylistic/eslint-plugin"
dependency-version: 5.7.1
dependency-type: direct:production
update-type: version-update:semver-minor
dependency-group: eslint
- dependency-name: eslint-plugin-jsdoc
dependency-version: 62.4.1
dependency-type: direct:production
update-type: version-update:semver-major
dependency-group: eslint
- dependency-name: globals
dependency-version: 17.2.0
dependency-type: direct:production
update-type: version-update:semver-major
dependency-group: eslint
...
Signed-off-by: dependabot[bot] <support@github.com >
PR-URL: https://github.com/nodejs/node/pull/61628
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Aviv Keller <me@aviv.sh >
2026-04-08 23:53:03 +02:00
Mike McCready
0d1975fe3a
build,win: add WinGet Visual Studio 2022 Build Tools Edition config
...
PR-URL: https://github.com/nodejs/node/pull/61652
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Stefan Stojanovic <stefan.stojanovic@janeasystems.com >
2026-04-08 23:53:03 +02:00
Nikita Skovoroda
458c92be52
events: don't call resume after close
...
PR-URL: https://github.com/nodejs/node/pull/60548
Fixes: https://github.com/nodejs/node/issues/60507
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Gürgün Dayıoğlu <hey@gurgun.day >
2026-04-08 23:53:03 +02:00
Juan José
2bf990bb1a
doc: update Juan's security steward info
...
Signed-off-by: Juan José Arboleda <soyjuanarbol@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/61754
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: Richard Lau <richard.lau@ibm.com >
Reviewed-By: Ulises Gascón <ulisesgascongonzalez@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Stewart X Addison <sxa@redhat.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-04-08 23:53:03 +02:00
Juan José
f4a3edc47a
fs: add throwIfNoEntry option for fs.stat and fs.promises.stat
...
Fixes: https://github.com/nodejs/node/issues/61116
Signed-off-by: Juan José Arboleda <soyjuanarbol@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/61178
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2026-04-08 23:53:03 +02:00
René
6834ca13bb
stream: rename Duplex.toWeb() type option to readableType
...
PR-URL: https://github.com/nodejs/node/pull/61632
Refs: https://github.com/nodejs/node/pull/58664
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Mattias Buelens <mattias@buelens.com >
2026-04-08 23:53:02 +02:00
Antoine du Hamel
0312db948d
doc: fix methods being documented as properties in process.md
...
PR-URL: https://github.com/nodejs/node/pull/61765
Reviewed-By: René <contact.9a5d6388@renegade334.me.uk >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-04-08 23:53:02 +02:00
Lu Yahan
e558b26e7f
doc: add riscv64 info into platform list
...
PR-URL: https://github.com/nodejs/node/pull/42251
Reviewed-By: Stewart X Addison <sxa@redhat.com >
2026-04-08 23:53:02 +02:00
Jeff
49254e3dc0
doc: fix dropdown menu being obscured at <600px due to stacking context
...
PR-URL: https://github.com/nodejs/node/pull/61735
Fixes: https://github.com/nodejs/node/issues/59282
Reviewed-By: Aviv Keller <me@aviv.sh >
Reviewed-By: Claudio Wunder <cwunder@gnome.org >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-04-08 23:53:02 +02:00
Aviv Keller
4ff01b5c10
doc: fix spacing in process message event
...
PR-URL: https://github.com/nodejs/node/pull/61756
Reviewed-By: René <contact.9a5d6388@renegade334.me.uk >
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-04-08 23:53:02 +02:00
Node.js GitHub Bot
b3387b07b1
deps: update googletest to 5a9c3f9e8d9b90bbbe8feb32902146cb8f7c1757
...
PR-URL: https://github.com/nodejs/node/pull/61731
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-04-08 23:53:02 +02:00
Node.js GitHub Bot
84c7a23223
test: update WPT for WebCryptoAPI to 7cbe7e8ed9
...
PR-URL: https://github.com/nodejs/node/pull/61729
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-04-08 23:53:02 +02:00
Node.js GitHub Bot
276a32fd10
test: update WPT for url to efb889eb4c
...
PR-URL: https://github.com/nodejs/node/pull/61728
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-04-08 23:53:02 +02:00
Joyee Cheung
e0220f0c35
build: build with v8 gdbjit support on supported platform
...
Build it with gdbjit support on supported platforms by default
allows debugging JIT-compiled code in gdb when it's also enabled
at run time (via --gdbjit). Simply building it in should not
incur an overhead if it's not also enabled at run time.
PR-URL: https://github.com/nodejs/node/pull/61010
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2026-04-08 23:53:02 +02:00
Antoine du Hamel
bc38db51fc
tools: fix small inconsistencies in JSON doc output
...
PR-URL: https://github.com/nodejs/node/pull/61757
Reviewed-By: Claudio Wunder <cwunder@gnome.org >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Aviv Keller <me@aviv.sh >
2026-04-08 23:53:02 +02:00
Anna Henningsen
3c8f700fd7
src: track allocations made by zstd streams
...
This is both valuable as a diagnostic tool and as a way to inform
the JS runtime about external allocations.
Currently, this is a feature only enabled in the statically linked
builds of zstd, so with `--shared-zstd`, we fall back to the
non-tracking variant.
PR-URL: https://github.com/nodejs/node/pull/61717
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
2026-04-08 23:53:01 +02:00
Anna Henningsen
94dbb36d4d
src: do not store compression methods on Brotli classes
...
This addresses a long-standing TODO comment, referencing the fact
that these values are either known at compile time or can be
inferred from the `this` value in the context class.
PR-URL: https://github.com/nodejs/node/pull/61717
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
2026-04-08 23:53:01 +02:00
Anna Henningsen
bef661f182
src: extract zlib allocation tracking into its own class
...
This makes it a bit easier to separate concerns, and results in
reduced code duplication when compiling since this code does not
depend on template parameters.
PR-URL: https://github.com/nodejs/node/pull/61717
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
2026-04-08 23:53:01 +02:00
Anna Henningsen
e8079a8297
src: release memory for zstd contexts in Close()
...
This aligns zstd streams with other compression libraries in this
regard, and enables releasing memory early when the stream ends in
JS instead of waiting for GC to clean up the wrapper object (which
is a problem that is exacerbated in the zstd context because we
do not track memory and report memory pressure to V8 yet).
PR-URL: https://github.com/nodejs/node/pull/61717
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
2026-04-08 23:53:01 +02:00
Luca Raveri
94097a79d6
doc: move describe/it aliases section before expectFailure
...
PR-URL: https://github.com/nodejs/node/pull/61567
Reviewed-By: Tierney Cyren <hello@bnb.im >
Reviewed-By: Jacob Smith <jacob@frende.me >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
Reviewed-By: Pietro Marchini <pietro.marchini94@gmail.com >
2026-04-08 23:53:01 +02:00
Joyee Cheung
6e1197a3cc
src: add more checks and clarify docs for external references
...
To help catch unregistered bindings.
PR-URL: https://github.com/nodejs/node/pull/61719
Refs: https://github.com/nodejs/node/pull/61718
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2026-04-08 23:53:01 +02:00
YuSheng Chen
b7cd31acbe
doc: fix broken links of net.md
...
PR-URL: https://github.com/nodejs/node/pull/61673
Reviewed-By: Richard Lau <richard.lau@ibm.com >
Reviewed-By: Tim Perry <pimterry@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Ulises Gascón <ulisesgascongonzalez@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-04-08 23:53:01 +02:00
Joyee Cheung
c28a22c4be
src: fix cjs_lexer external reference registration
...
It needs to be added to the list to actually get registered.
PR-URL: https://github.com/nodejs/node/pull/61718
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2026-04-08 23:53:01 +02:00
Karan Mangtani
171e9fc268
esm: update outdated FIXME comment in translators.js
...
PR-URL: https://github.com/nodejs/node/pull/61715
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2026-04-08 23:53:01 +02:00
sangwook
687c0acd00
http2: fix FileHandle leak in respondWithFile
...
Ensure that the file handle is closed if header validation fails in
respondWithFile. This prevents ERR_INVALID_STATE errors where a
FileHandle object is closed during garbage collection.
PR-URL: https://github.com/nodejs/node/pull/61707
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Tim Perry <pimterry@gmail.com >
2026-04-08 23:53:00 +02:00
reillylm
ae5e353fe2
doc: clean up Windows code snippet in child_process.md
...
PR-URL: https://github.com/nodejs/node/pull/61422
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2026-04-08 23:53:00 +02:00
Mike McCready
ea9beb6a3c
doc: update to Visual Studio 2026 manual install
...
PR-URL: https://github.com/nodejs/node/pull/61655
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Stefan Stojanovic <stefan.stojanovic@janeasystems.com >
2026-04-08 23:53:00 +02:00
Amol Yadav
c851e76f8c
net: add setTOS and getTOS to Socket
...
PR-URL: https://github.com/nodejs/node/pull/61503
Fixes: https://github.com/nodejs/node/issues/61489
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Robert Nagy <ronagy@icloud.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2026-04-08 23:53:00 +02:00
Chengzhong Wu
83dfd0be1d
buffer: disallow ArrayBuffer transfer on pooled buffer
...
PR-URL: https://github.com/nodejs/node/pull/61372
Fixes: https://github.com/nodejs/node/issues/61362
Refs: https://github.com/v8/v8/commit/c5ff7c4d6cdea06d0319609875c41eaa77b70db0
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: René <contact.9a5d6388@renegade334.me.uk >
2026-04-08 23:53:00 +02:00
Chengzhong Wu
196268cb4c
deps: V8: cherry-pick c5ff7c4d6cde
...
Original commit message:
[builtins] disallow ArrayBuffer transfer with a detach key
This allows embedder to disallow `ArrayBuffer.prototype.transfer()` on
an arraybuffer that is not detachable. This also fix the check on
`ArrayBufferCopyAndDetach` step 8 of `ArrayBuffer.prototype.transfer`.
Refs: https://github.com/nodejs/node/issues/61362
Refs: https://tc39.es/ecma262/#sec-arraybuffercopyanddetach
Change-Id: I3c6e156a8fad007fd100218d8b16aed5c4e1db68
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/7454288
Commit-Queue: Chengzhong Wu <cwu631@bloomberg.net >
Reviewed-by: Olivier Flückiger <olivf@chromium.org >
Cr-Commit-Position: refs/heads/main@{#104697}
Refs: https://github.com/v8/v8/commit/c5ff7c4d6cdea06d0319609875c41eaa77b70db0
PR-URL: https://github.com/nodejs/node/pull/61372
Fixes: https://github.com/nodejs/node/issues/61362
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: René <contact.9a5d6388@renegade334.me.uk >
2026-04-08 23:53:00 +02:00
Ryuhei Shima
5505511dcb
build: enable -DV8_ENABLE_CHECKS flag
...
Fixes: https://github.com/nodejs/node/issues/61301
PR-URL: https://github.com/nodejs/node/pull/61327
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2026-04-08 23:53:00 +02:00
Gerhard Stöbich
83cffd92b5
async_hooks: enabledHooksExist shall return if hooks are enabled
...
Correct the implementaton of enabledHooksExist to return true if
there are enabled hooks.
Adapt callsites which used getHooksArrays() as workaround.
PR-URL: https://github.com/nodejs/node/pull/61054
Fixes: https://github.com/nodejs/node/issues/61019
Refs: https://github.com/nodejs/node/pull/59873
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Gürgün Dayıoğlu <hey@gurgun.day >
2026-04-08 23:53:00 +02:00
Ruben Bridgewater
148373cea1
assert,util: improve comparison performance
...
This makes sure that the toStringTag symbol is used, if available
instead of calculating the toString() value each time, if not
needed (the type checks make a brand check, so there is no need to
check the toStringTag, if non is defined on the object).
PR-URL: https://github.com/nodejs/node/pull/61176
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
2026-04-08 23:52:59 +02:00
Joyee Cheung
5f8ecf3940
build: add --debug-symbols to build with -g without enabling DCHECKs
...
This is useful when debugging release builds on Linux without
enabling DCHECKs.
PR-URL: https://github.com/nodejs/node/pull/61100
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2026-04-08 23:52:59 +02:00
Ruben Bridgewater
e5558b0859
assert,util: fix deep comparing invalid dates skipping properties
...
The property comparison of invalid dates regressed when starting
to handle invalid dates as being equal.
PR-URL: https://github.com/nodejs/node/pull/61076
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2026-04-08 23:52:59 +02:00
Joyee Cheung
8b6be3fe14
module: mark require(esm) as stable
...
This has been released to all active LTS release lines and many
popular packages have been shipping ESM-only distributions based
on the existence of this feature on active LTS. The current documented
behaviors are unlikely to change in a breaking manner within a major
release - as everything with the module loaders, there can always be
subtle changes to undocumented surface that can break edge cases that
assume undocumented behaviors, due to Hyrum's law; but the stability
of this feature is now not different than any other stable parts of
the module loader. It's time to mark it as stable.
PR-URL: https://github.com/nodejs/node/pull/60959
Reviewed-By: Jacob Smith <jacob@frende.me >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: Jordan Harband <ljharb@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2026-04-08 23:52:59 +02:00
Joyee Cheung
83c38672f7
cli: add --require-module/--no-require-module
...
To replace --experimental-require-module and
--no-experimental-require-module. The experimental
ones are left as legacy aliases.
PR-URL: https://github.com/nodejs/node/pull/60959
Reviewed-By: Jacob Smith <jacob@frende.me >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: Jordan Harband <ljharb@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2026-04-08 23:52:59 +02:00
Joyee Cheung
68fbc0c6cc
module: mark module compile cache as stable
...
The feature set has been stable without any breaking changes
in the past year, and it's been depended enough in the wild
by popular packages that we'll likely need to treat any breakages
as semver-major in the future anyway. The future TODOs are likely
all non-breaking. Potential subtle breakages in implementation
details that should not be relied upon (such as the cache layout)
are explicitly excluded from the contract.
We'll investigate whether it can be enabled by default as a
different topic, which can be potentially semver-major.
PR-URL: https://github.com/nodejs/node/pull/60971
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
2026-04-08 23:52:59 +02:00
Michaël Zasso
3e7010d47f
tools: refloat 10 Node.js patches to cpplint.py
...
Cherry-pick 12c8b4d154
Original commit message:
This commit is a suggestion for adding a rule for NULL usages in the
code base. This will currently report a number of errors which could be
ignored using // NOLINT (readability/null_usage)
PR-URL: https://github.com/nodejs/node/pull/17373
Reviewed-By: Jon Moss <me@jonathanmoss.me >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Timothy Gu <timothygu99@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Refs: https://github.com/nodejs/node/commit/12c8b4d15471cb6211b39c3a2ca5b10fa4b9f12b
Cherry-pick fc81e80191
Original commit message:
Update cpplint.py to check for inline headers when the corresponding
header is already included.
PR-URL: https://github.com/nodejs/node/pull/21521
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: James M Snell <jasnell@gmail.com >
Refs: https://github.com/nodejs/node/commit/fc81e801913de3e3f3c0c8e26c105f983a74e539
Cherry-pick cbc3dd997e
Original commit message:
src, tools: add check for left leaning pointers
This commit adds a rule to cpplint to check that pointers in the code
base lean to the left and not right, and also fixes the violations
reported.
PR-URL: https://github.com/nodejs/node/pull/21010
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
Refs: https://github.com/nodejs/node/commit/cbc3dd997eb90d629d1b9912b7a5a40eb82343df
Cherry-pick 902998190a
Original commit message:
tools: fix cpplint.py header rules
THIS COMMIT SHOULD GO WITH THE NEXT. IT WILL FIND NEW LINT.
PR-URL: https://github.com/nodejs/node/pull/26306
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Refs: https://github.com/nodejs/node/commit/902998190a55d6915b881936f6dd5b6e9cca6ad8
Cherry-pick 0a25ace9c3
Original commit message:
tools: move cpplint configuration to .cpplint
PR-URL: https://github.com/nodejs/node/pull/27098
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com >
Refs: https://github.com/nodejs/node/commit/0a25ace9c35b62ece4d32fd90b326d8063265109
Cherry-pick afa9a7206c
Original commit message:
tools: refloat update link to google styleguide for cpplint
This commit updates two old links to Google's C++ styleguide which
currently result in a 404 when accessed.
PR-URL: https://github.com/nodejs/node/pull/30876
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: David Carlier <devnexen@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Refs: https://github.com/nodejs/node/commit/afa9a7206c26a29a2af226696c145c924a6d3754
Cherry-pick e23bf8f771
Original commit message:
tools,src: refloat forbid usage of v8::Persistent
`v8::Persistent` comes with the surprising catch that it requires
manual cleanup. `v8::Global` doesn’t, making it easier to use,
and additionally provides move semantics. New code should always
use `v8::Global`.
PR-URL: https://github.com/nodejs/node/pull/31018
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: David Carlier <devnexen@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Gus Caplan <me@gus.host >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
Backport 3d954dcf81
Original commit message:
tools: remove readability/fn_size rule
PR-URL: https://github.com/nodejs/node/pull/54663
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Refs: https://github.com/nodejs/node/commit/3d954dcf812bb500a77913ffd5ebec76235714f0
Cherry-pick c7d7ec7cda
Original commit message:
tools: check for std::vector<v8::Local> in lint
PR-URL: https://github.com/nodejs/node/pull/58497
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Juan José Arboleda <soyjuanarbol@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Refs: https://github.com/nodejs/node/commit/c7d7ec7cda56b7776797cbdef3d4497fc98e8440
Cherry-pick e6d94ef106
Original commit message:
tools: add C++ lint rule to avoid using `String::Utf8Value`
We should be using our own helpers for this instead.
PR-URL: https://github.com/nodejs/node/pull/60244
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Edy Silva <edigleyssonsilva@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ilyas Shabi <ilyasshabi94@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Vladimir Morozov <vmorozov@microsoft.com >
Refs: https://github.com/nodejs/node/commit/e6d94ef106e08999e5461dabfeb333ff141f59fe
PR-URL: https://github.com/nodejs/node/pull/60901
Fixes: https://github.com/nodejs/node/issues/60771
2026-04-08 23:52:59 +02:00