Chengzhong Wu
d9700fef26
lib: avoid StackOverflow on serializeError
...
`serializeError` should avoid StackOverflow and the test should not
rely on `--stack-size`.
PR-URL: https://github.com/nodejs/node/pull/58075
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
2025-05-19 12:14:04 +02:00
0hm☘️🏳️⚧️
f3a16b6d9c
lib: resolve the issue of not adhering to the specified buffer size
...
We create a `queueHandler`, and in every iteration we execute
the handlers in the `queueHandler` until we get a non-null result.
PR-URL: https://github.com/nodejs/node/pull/55896
Refs: https://github.com/nodejs/node/issues/55764
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: James M Snell <jasnell@gmail.com >
2025-05-19 12:14:02 +02:00
Dario Piotrowicz
af41dd3c07
watch: clarify completion/failure watch mode messages
...
clarify the messages that `node --watch` presents to the user
when the process terminates (either successfully or because of
some error) by clearly conveying that node is waiting for new
file changes before restarting the process
PR-URL: https://github.com/nodejs/node/pull/57926
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
2025-05-19 12:14:02 +02:00
Antoine du Hamel
53c5fdcae1
crypto: fix cross-realm SharedArrayBuffer validation
...
PR-URL: https://github.com/nodejs/node/pull/57974
Reviewed-By: Jordan Harband <ljharb@gmail.com >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2025-05-19 12:14:02 +02:00
Felipe Forbeck
78f4ffee5d
crypto: fix cross-realm check of ArrayBuffer
...
This patch modifies the `isNonSharedArrayBuffer` function in the WebIDL
implementation for the SubtleCrypto API to properly handle `ArrayBuffer`
instances created in different JavaScript realms.
Before this fix, when a `TypedArray.buffer` from a different realm
(e.g., from a VM context or worker thread) was passed to
`SubtleCrypto.digest()`, it would fail with:
> TypeError: Failed to execute 'digest' on 'SubtleCrypto': 2nd argument
> is not instance of ArrayBuffer, Buffer, TypedArray, or DataView."
The fix use the `isArrayBuffer` function from `internal/util/types` to
detect cross-realm `ArrayBuffer` instances when the prototype chain
check fails.
PR-URL: https://github.com/nodejs/node/pull/57828
Refs: https://github.com/storacha/w3up/issues/1591
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Jordan Harband <ljharb@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2025-05-19 12:14:01 +02:00
Wiyeong Seo
a4105db1f7
os: fix netmask format check condition in getCIDR function
...
Modified to check the format of the netmask instead
of just checking that each part of the netmask is even
PR-URL: https://github.com/nodejs/node/pull/57324
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2025-05-19 12:14:00 +02:00
Livia Medeiros
4252dc798c
assert: support Float16Array in loose deep equality checks
...
PR-URL: https://github.com/nodejs/node/pull/57881
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2025-05-19 12:14:00 +02:00
Kushagra Pandey
137717354f
http2: fix graceful session close
...
Fix issue where session.close() prematurely destroys the session
when response.end() was called with an empty payload while active
http2 streams still existed. This change ensures that sessions are
closed gracefully only after all http2 streams complete and clients
properly receive the GOAWAY frame as per the HTTP/2 spec.
Refs: https://nodejs.org/api/http2.html\#http2sessionclosecallback
PR-URL: https://github.com/nodejs/node/pull/57808
Fixes: https://github.com/nodejs/node/issues/57809
Refs: https://nodejs.org/api/http2.html%5C#http2sessionclosecallback
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Tim Perry <pimterry@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2025-05-19 12:13:59 +02:00
Abdirahim Musse
248c938139
process: disable building execve on IBM i
...
The `execve` syscall does exist on IBM i but
it has caveats that make it not usable in Node.js context.
These changes disable building with `execve` like Windows does.
PR-URL: https://github.com/nodejs/node/pull/57883
Reviewed-By: Michael Dawson <midawson@redhat.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Paolo Insogna <paolo@cowtech.it >
2025-05-19 12:13:59 +02:00
Gürgün Dayıoğlu
d4fc282f73
lib: fix AbortSignal.any() with timeout signals
...
PR-URL: https://github.com/nodejs/node/pull/57867
Reviewed-By: Edy Silva <edigleyssonsilva@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
2025-05-19 12:13:59 +02:00
Shima Ryuhei
416052a9f2
util: fix formatting of objects with built-in Symbol.toPrimitive
...
Fixes: https://github.com/nodejs/node/issues/57818
PR-URL: https://github.com/nodejs/node/pull/57832
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2025-05-19 12:13:58 +02:00
Matteo Collina
dda6ca9172
worker: add worker.getHeapStatistics()
...
Adds worker.getHeapStatistics() so that the heap usage of the worker
could be observer from the parent thread.
Signed-off-by: Matteo Collina <hello@matteocollina.com >
PR-URL: https://github.com/nodejs/node/pull/57888
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
2025-05-19 12:13:58 +02:00
Livia Medeiros
f606352b63
crypto: forbid passing Float16Array to getRandomValues()
...
PR-URL: https://github.com/nodejs/node/pull/57880
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
2025-05-19 12:13:58 +02:00
Livia Medeiros
43490c8797
util: add types.isFloat16Array()
...
PR-URL: https://github.com/nodejs/node/pull/57879
Reviewed-By: Jordan Harband <ljharb@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2025-05-19 12:13:58 +02:00
Shima Ryuhei
edb7dd1ec7
test_runner: match minimum file column to 'all files'
...
PR-URL: https://github.com/nodejs/node/pull/57848
Reviewed-By: Pietro Marchini <pietro.marchini94@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Jake Yuesong Li <jake.yuesong@gmail.com >
2025-05-19 12:13:57 +02:00
Livia Medeiros
30060e13d3
util: preserve length of deprecated functions
...
PR-URL: https://github.com/nodejs/node/pull/57806
Reviewed-By: Jordan Harband <ljharb@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
2025-05-19 12:13:55 +02:00
haykam821
44c5718476
module: fix incorrect formatting in require(esm) cycle error message
...
Fixes: https://github.com/nodejs/node/issues/57451
PR-URL: https://github.com/nodejs/node/pull/57453
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Jake Yuesong Li <jake.yuesong@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2025-05-19 12:13:55 +02:00
Tobias Nießen
c6a45a9087
Revert "test: add tests for REPL custom evals"
...
This reverts commit 1f7cfb7a36 , which was
merged into the main branch despite relevant test failures.
PR-URL: https://github.com/nodejs/node/pull/57793
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Richard Lau <rlau@redhat.com >
2025-05-19 12:13:54 +02:00
Gürgün Dayıoğlu
f7e2902861
lib: use Map primordial for ActiveAsyncContextFrame
...
PR-URL: https://github.com/nodejs/node/pull/57670
Reviewed-By: Jordan Harband <ljharb@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Gerhard Stöbich <deb2001-github@yahoo.de >
2025-05-19 12:13:54 +02:00
Rich Trott
8f643471ef
fs: improve globSync performance
...
PR-URL: https://github.com/nodejs/node/pull/57725
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
2025-05-19 12:13:53 +02:00
Dario Piotrowicz
f3a4d03963
test: add tests for REPL custom evals
...
PR-URL: https://github.com/nodejs/node/pull/57691
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2025-05-19 12:13:53 +02:00
Jason Zhang and Jake Yuesong Li
7229a29b47
watch: check parent and child path properly
...
Co-authored-by: Jake Yuesong Li <jake.yuesong@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/57425
Fixes: https://github.com/nodejs/node/issues/57422
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
2025-05-19 12:13:52 +02:00
Dario Piotrowicz
bb09b4d4ae
module: improve getPackageType performance
...
PR-URL: https://github.com/nodejs/node/pull/57599
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Ulises Gascón <ulisesgascongonzalez@gmail.com >
2025-05-19 12:13:52 +02:00
Dario Piotrowicz
9e6054e715
module: remove unnecessary readPackage function
...
PR-URL: https://github.com/nodejs/node/pull/57596
Reviewed-By: Jacob Smith <jacob@frende.me >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
2025-05-19 12:13:52 +02:00
Dario Piotrowicz and Antoine du Hamel
972275697a
repl: deprecate repl.builtinModules
...
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/57508
Reviewed-By: Juan José Arboleda <soyjuanarbol@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Xuguang Mei <meixuguang@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Zijian Liu <lxxyxzj@gmail.com >
2025-05-19 12:13:51 +02:00
Shima Ryuhei
b8189242b2
http2: skip writeHead if stream is closed
...
Fixes: https://github.com/nodejs/node/issues/57416
PR-URL: https://github.com/nodejs/node/pull/57686
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Tim Perry <pimterry@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Jake Yuesong Li <jake.yuesong@gmail.com >
2025-05-19 12:13:51 +02:00
Guy Bedford
832640c35e
esm: support top-level Wasm without package type
...
PR-URL: https://github.com/nodejs/node/pull/57610
Reviewed-By: Jordan Harband <ljharb@gmail.com >
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2025-05-19 12:13:50 +02:00
Ruben Bridgewater
696b5f85ca
assert,util: improve unequal number comparison performance
...
This improves the performance to compare unequal numbers while doing
a deep equal comparison. Comparing for NaN is faster by checking
`variable !== variable` than by using `Number.isNaN()`.
PR-URL: https://github.com/nodejs/node/pull/57619
Reviewed-By: Jordan Harband <ljharb@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Edy Silva <edigleyssonsilva@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
2025-05-19 12:13:48 +02:00
Ruben Bridgewater
775ee4d40f
assert,util: improve array comparison
...
Sparse arrays and arrays containing undefined are now compared faster
using assert.deepStrictEqual() or util.isDeepStrictEqual().
PR-URL: https://github.com/nodejs/node/pull/57619
Reviewed-By: Jordan Harband <ljharb@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Edy Silva <edigleyssonsilva@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
2025-05-19 12:13:48 +02:00
Gürgün Dayıoğlu
d1da9a3a2f
timers: optimize timer functions with improved argument handling
...
PR-URL: https://github.com/nodejs/node/pull/57072
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
Reviewed-By: Gerhard Stöbich <deb2001-github@yahoo.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2025-04-17 10:51:54 -03:00
Paolo Insogna
2ce79787de
process: add execve
...
PR-URL: https://github.com/nodejs/node/pull/56496
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Bryan English <bryan@bryanenglish.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2025-04-17 10:51:51 -03:00
Demian Parkhomenko
1b5418eeea
lib: add warning when binding inspector to public IP
...
Add `isLoopback` function to `internal/net` module to check if a given
host is a loopback address.
Add a warning when binding the inspector to a public IP with an open
port, as it allows external hosts to connect to the inspector.
Fixes: https://github.com/nodejs/node/issues/23444
Refs: https://nodejs.org/api/cli.html#--inspecthostport
PR-URL: https://github.com/nodejs/node/pull/55736
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: LiviaMedeiros <livia@cirno.name >
2025-04-17 10:51:51 -03:00
fengmk2
e301098854
util: avoid run debug when enabled is false
...
it can improve performace 700x faster
PR-URL: https://github.com/nodejs/node/pull/57494
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Jordan Harband <ljharb@gmail.com >
2025-04-17 10:51:50 -03:00
Gürgün Dayıoğlu
44aa13990a
timers: remove unnecessary allocation of _onTimeout
...
PR-URL: https://github.com/nodejs/node/pull/57497
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Gerhard Stöbich <deb2001-github@yahoo.de >
2025-04-17 10:51:49 -03:00
Giovanni Bucci
17016d7722
util: expose diff function used by the assertion errors
...
fix: https://github.com/nodejs/node/issues/51740
PR-URL: https://github.com/nodejs/node/pull/57462
Fixes: https://github.com/nodejs/node/issues/51740
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Pietro Marchini <pietro.marchini94@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2025-04-17 10:51:49 -03:00
Ruben Bridgewater
ea70a379c3
assert: improve partialDeepStrictEqual performance
...
This implements fast paths for typed arrays, array buffers and sets
and maps that contain only objects as keys.
PR-URL: https://github.com/nodejs/node/pull/57509
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
2025-04-17 10:51:48 -03:00
Dario Piotrowicz and Xuguang Mei
caf81ca549
debugger: fix behavior of plain object exec in debugger repl
...
Co-authored-by: Xuguang Mei <meixuguang@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/57498
Fixes: https://github.com/nodejs/node/issues/46808
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Xuguang Mei <meixuguang@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2025-04-17 10:51:47 -03:00
Colin Ihrig
bb3bbed126
sqlite: add DatabaseSync.prototype[Symbol.dispose]()
...
This commit adds support for the explicit resource management
proposal to the sqlite module.
Refs: https://github.com/nodejs/node/pull/53752#discussion_r1667750387
PR-URL: https://github.com/nodejs/node/pull/57506
Reviewed-By: Zeyu "Alex" Yang <himself65@outlook.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Edy Silva <edigleyssonsilva@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ulises Gascón <ulisesgascongonzalez@gmail.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
2025-04-17 10:51:46 -03:00
Gürgün Dayıoğlu
cc4d33842b
lib: limit split function calls to prevent excessive array length
...
PR-URL: https://github.com/nodejs/node/pull/57501
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Jacob Smith <jacob@frende.me >
2025-04-17 10:51:46 -03:00
Filip Skokan
ada572b733
crypto: ensure expected JWK alg in SubtleCrypto.importKey RSA imports
...
PR-URL: https://github.com/nodejs/node/pull/57450
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2025-04-17 10:51:45 -03:00
Marco Ippolito
10d2f1d898
http: coerce content-length to number
...
PR-URL: https://github.com/nodejs/node/pull/57458
Fixes: https://github.com/nodejs/node/issues/57456
Reviewed-By: Tim Perry <pimterry@gmail.com >
Reviewed-By: Paolo Insogna <paolo@cowtech.it >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2025-04-17 10:51:45 -03:00
Rich Trott
2de27787b4
fs: apply exclude function to root path
...
In at least some situations, the root path was
being added to the results of globbing even if
it matched the optional exclude function.
In the relevant test file, a variable was renamed
for consistency. (There was a patterns and pattern2,
rather than patterns2.) The test case is added to
patterns2.
Fixes: https://github.com/nodejs/node/issues/56260
PR-URL: https://github.com/nodejs/node/pull/57420
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Jason Zhang <xzha4350@gmail.com >
Reviewed-By: LiviaMedeiros <livia@cirno.name >
Reviewed-By: James M Snell <jasnell@gmail.com >
2025-04-17 10:51:44 -03:00
James M Snell
0546612d1d
lib: make getCallSites sourceMap option truly optional
...
When calling the `util.getCallSites(...)` API, if the `options`
argument is omitted, then the `options.sourceMap` option is defaulted
to false. However, if any empty `options` is passed, it would throw
an error is `sourceMap` was not explicitly given. This relaxes that
so that `sourceMap` can be left unspecified.
For instance, before this commit, `getCallSites({})` would throw an
error.
Also, add more test coverage of this.
PR-URL: https://github.com/nodejs/node/pull/57388
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Jason Zhang <xzha4350@gmail.com >
2025-04-17 10:51:42 -03:00
Yagiz Nizipli
01215af350
tls: remove unnecessary type check on normalize
...
PR-URL: https://github.com/nodejs/node/pull/57336
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2025-04-17 10:51:40 -03:00
Gürgün Dayıoğlu
401b965977
timers: remove unused parameter from insertGuarded
...
PR-URL: https://github.com/nodejs/node/pull/57251
Reviewed-By: Juan José Arboleda <soyjuanarbol@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2025-04-17 10:51:40 -03:00
Ruben Bridgewater
2b419d7e79
assert: implement partial error comparison
...
assert.partialDeepStrictEqual now also handled error properties as
expected. On top of that, the main implementation also handles
non-string `name` and `message` properties and the comparison is a
tad faster by removing duplicated comparison steps.
As a drive-by fix this also cleans up some code by abstracting code
and renaming variables for clarity.
PR-URL: https://github.com/nodejs/node/pull/57370
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
2025-04-17 10:51:39 -03:00
Ruben Bridgewater
01cf5fb871
assert,util: improve performance
...
This improves the performance for array comparison by making the
sparse array detection simpler. On top of that it adds a fast path
for sets and maps that only contain objects as key.
PR-URL: https://github.com/nodejs/node/pull/57370
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
2025-04-17 10:51:39 -03:00
Ruben Bridgewater
d817c17fd7
assert: improve partialDeepStrictEqual
...
This significantly improves the assert.partialDeepStrictEqual
implementation by reusing the already existing algorithm.
It is significantly faster and handles edge cases like symbols
identical as the deepStrictEqual algorithm. This is crucial to
remove the experimental status from the implementation.
PR-URL: https://github.com/nodejs/node/pull/57370
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
2025-04-17 10:51:38 -03:00
Pietro Marchini
1b33b976ec
test_runner: refactor testPlan counter increse
...
PR-URL: https://github.com/nodejs/node/pull/56765
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
2025-04-17 10:51:37 -03:00
Eddie Abbondanzio
d860f2bf42
test_runner: differentiate test types in enqueue dequeue events
...
PR-URL: https://github.com/nodejs/node/pull/54049
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: Pietro Marchini <pietro.marchini94@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
2025-04-17 10:51:37 -03:00