Maël Nison
914db60159
http2: expose nghttp2_option_set_stream_reset_rate_limit as an option
...
PR-URL: https://github.com/nodejs/node/pull/54875
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Richard Lau <rlau@redhat.com >
2024-10-04 19:20:18 +02:00
Antoine du Hamel
c308862d2e
test_runner: avoid spread operator on arrays
...
PR-URL: https://github.com/nodejs/node/pull/55143
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2024-10-04 19:20:18 +02:00
Antoine du Hamel
b1ebb0d8ca
buffer: coerce extrema to int in blob.slice
...
PR-URL: https://github.com/nodejs/node/pull/55141
Fixes: https://github.com/nodejs/node/issues/55139
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2024-10-04 19:20:17 +02:00
Aviv Keller
12401972b7
test_runner: support typescript files in default glob
...
PR-URL: https://github.com/nodejs/node/pull/55081
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2024-10-04 19:20:17 +02:00
Giovanni
e3619510c8
assert: show the diff when deep comparing data with a custom message
...
Fixes: https://github.com/nodejs/node/issues/48465
PR-URL: https://github.com/nodejs/node/pull/54759
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2024-10-04 19:20:16 +02:00
Colin Ihrig
19cfa3140f
test_runner: close and flush destinations on forced exit
...
This commit updates the test runner to explicitly close and flush
all destination file streams when the --test-force-exit flag is
used.
Fixes: https://github.com/nodejs/node/issues/54327
PR-URL: https://github.com/nodejs/node/pull/55099
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
Reviewed-By: Jake Yuesong Li <jake.yuesong@gmail.com >
2024-10-04 19:20:16 +02:00
Aviv Keller
86f7cb802d
test_runner: support custom arguments in run()
...
PR-URL: https://github.com/nodejs/node/pull/55126
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2024-10-04 19:20:15 +02:00
Aviv Keller
1dcc5eedff
Revert "console: colorize console error and warn"
...
This reverts commit a833c9e0be .
PR-URL: https://github.com/nodejs/node/pull/54677
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
2024-10-04 19:20:15 +02:00
Carlos Espa
0bb5584288
src: add receiver to fast api callback methods
...
When creating an fast api the callback might use the receiver. In that
case if the internal binding is destructured the method won't have
access to the reciver and it will throw. Passing the receiver as second
argument ensures the receiver is available.
PR-URL: https://github.com/nodejs/node/pull/54408
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
2024-10-04 19:20:14 +02:00
Jason Zhang
a9675a0cbc
stream: treat null asyncIterator as undefined
...
According to the spec, getIterator should normalize incoming method to
undefined if it is either undefined or null. This PR enforces that spec
compliance with passed WPT.
PR-URL: https://github.com/nodejs/node/pull/55119
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Matthew Aitken <maitken033380023@gmail.com >
Reviewed-By: Mattias Buelens <mattias@buelens.com >
2024-10-04 19:20:13 +02:00
Antoine du Hamel
0fb446e207
esm: do not interpret "main" as a URL
...
As documented, its value is a path.
PR-URL: https://github.com/nodejs/node/pull/55003
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
2024-10-04 19:20:13 +02:00
RedYetiDev and Antoine du Hamel
32261fc98a
module: support loading entrypoint as url
...
Co-Authored-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/54933
Refs: https://github.com/nodejs/node/pull/49975
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: LiviaMedeiros <livia@cirno.name >
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2024-10-04 19:20:12 +02:00
Khafra
3a6e72483f
buffer: extract Blob's .arrayBuffer() & webidl changes
...
- Extracts Blob.prototype.arrayBuffer so it cannot be
overridden in .text(), etc.
- Make .bytes() enumerable. I guess the WPT runner is
not running the idlharness tests?
- Make .text() return a Promise, rather than being
explicitly async. This is a non-documented part of
the webidl spec. Refs: #49936
- Have .text(), .arrayBuffer(), and .bytes() reject
for an invalid this instead of throwing. Fix the
tests regarding this.
PR-URL: https://github.com/nodejs/node/pull/53372
Refs: https://github.com/nodejs/node/pull/49936
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
2024-10-04 10:20:29 +02:00
Antoine du Hamel
7eaeba499a
test_runner: fix mocking modules with quote in their URL
...
PR-URL: https://github.com/nodejs/node/pull/55083
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Tierney Cyren <hello@bnb.im >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
2024-10-04 10:20:27 +02:00
Nathan Baulch
bf7d7aef4b
lib: fix typos
...
PR-URL: https://github.com/nodejs/node/pull/55065
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: LiviaMedeiros <livia@cirno.name >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2024-10-04 10:20:26 +02:00
Aviv Keller
566179c9ec
lib, tools: remove duplicate requires
...
PR-URL: https://github.com/nodejs/node/pull/54987
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2024-10-04 10:20:25 +02:00
Aviv Keller
538b1eb5b0
repl: catch \v and \r in new-line detection
...
PR-URL: https://github.com/nodejs/node/pull/54512
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: LiviaMedeiros <livia@cirno.name >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2024-10-04 10:20:25 +02:00
Joyee Cheung
111261e245
module: implement the "module-sync" exports condition
...
This patch implements a "module-sync" exports condition
for packages to supply a sycnrhonous ES module to the
Node.js module loader, no matter it's being required
or imported. This is similar to the "module" condition
that bundlers have been using to support `require(esm)`
in Node.js, and allows dual-package authors to opt into
ESM-first only newer versions of Node.js that supports
require(esm) while avoiding the dual-package hazard.
```json
{
"type": "module",
"exports": {
"node": {
// On new version of Node.js, both require() and import get
// the ESM version
"module-sync": "./index.js",
// On older version of Node.js, where "module" and
// require(esm) are not supported, use the transpiled CJS version
// to avoid dual-package hazard. Library authors can decide
// to drop support for older versions of Node.js when they think
// it's time.
"default": "./dist/index.cjs"
},
// On any other environment, use the ESM version.
"default": "./index.js"
}
}
```
We end up implementing a condition with a different name
instead of reusing "module", because existing code in the
ecosystem using the "module" condition sometimes also expect
the module resolution for these ESM files to work in CJS
style, which is supported by bundlers, but the native
Node.js loader has intentionally made ESM resolution
different from CJS resolution (e.g. forbidding `import
'./noext'` or `import './directory'`), so it would be
semver-major to implement a `"module"` condition
without implementing the forbidden ESM resolution rules.
For now, this just implments a new condition as semver-minor
so it can be backported to older LTS.
Refs: https://webpack.js.org/guides/package-exports/#target-environment-independent-packages
PR-URL: https://github.com/nodejs/node/pull/54648
Fixes: https://github.com/nodejs/node/issues/52173
Refs: https://github.com/joyeecheung/test-module-condition
Refs: https://github.com/nodejs/node/issues/52697
Reviewed-By: Jacob Smith <jacob@frende.me >
Reviewed-By: Jan Krems <jan.krems@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2024-10-04 10:20:25 +02:00
Jason Zhang
bf69ae1406
stream: set stream prototype to closest transferable superclass
...
PR-URL: https://github.com/nodejs/node/pull/55067
Fixes: https://github.com/nodejs/node/issues/54603
Refs: https://github.com/nodejs/node/pull/50107
Reviewed-By: Mattias Buelens <mattias@buelens.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
2024-10-04 10:20:25 +02:00
Aviv Keller
0f01f38aea
tty: fix links for terminal colors
...
PR-URL: https://github.com/nodejs/node/pull/54596
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
2024-10-04 10:20:24 +02:00
Aviv Keller
d803355d92
lib: prefer optional chaining
...
PR-URL: https://github.com/nodejs/node/pull/55045
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Paolo Insogna <paolo@cowtech.it >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
2024-10-04 10:20:24 +02:00
Luke Taher
cbfc980f89
perf_hooks: add missing type argument to getEntriesByName
...
Fixes: https://github.com/nodejs/node/issues/54766
PR-URL: https://github.com/nodejs/node/pull/54767
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2024-10-04 10:20:23 +02:00
Aviv Keller
a97c80c6ae
doc: add note about --expose-internals
...
PR-URL: https://github.com/nodejs/node/pull/52861
Reviewed-By: Jan Krems <jan.krems@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
2024-10-04 10:20:22 +02:00
Yagiz Nizipli
d4873bcd6d
lib: remove lib/internal/idna.js
...
PR-URL: https://github.com/nodejs/node/pull/55050
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
2024-10-04 10:20:22 +02:00
Filip Skokan
d3f8c35320
crypto: ensure invalid SubtleCrypto JWK data import results in DataError
...
PR-URL: https://github.com/nodejs/node/pull/55041
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2024-10-04 10:20:21 +02:00
8818c6c88a
test_runner: report error on missing sourcemap source
...
Co-Authored-By: Jayden Seric <me@jaydenseric.com >
Co-Authored-By: Colin Ihrig <cjihrig@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/55037
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2024-10-04 10:20:20 +02:00
Aviv Keller
b6fc9adf5b
module: remove duplicated import
...
PR-URL: https://github.com/nodejs/node/pull/54942
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2024-10-04 10:20:19 +02:00
Colin Ihrig
b62f2f8259
test_runner: add 'test:summary' event
...
This commit adds a new 'test:summary' event to the test runner's
reporting interface. This new event serves two purposes:
- In the future, the test runner internals will no longer need to
change the process exit code. This may be important to run()
users. Unfortunately, this is a breaking change, so it needs to
be changed in a major version.
- The reporting interface now has a single event that can identify
passing or failing test runs.
Refs: https://github.com/nodejs/node/issues/53867
Refs: https://github.com/nodejs/node/issues/54812
PR-URL: https://github.com/nodejs/node/pull/54851
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2024-10-04 10:20:18 +02:00
RedYetiDev
449dad0db0
test_runner: use test: symbol on second print of parent test
...
PR-URL: https://github.com/nodejs/node/pull/54956
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: James M Snell <jasnell@gmail.com >
2024-10-04 10:20:17 +02:00
Aviv Keller
d264639f5f
util: update ansi regex
...
PR-URL: https://github.com/nodejs/node/pull/54865
Refs: https://github.com/chalk/ansi-regex/pull/58
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: James M Snell <jasnell@gmail.com >
2024-10-04 10:20:17 +02:00
Yagiz Nizipli
a9fa2da870
zlib: throw brotli initialization error from c++
...
PR-URL: https://github.com/nodejs/node/pull/54698
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Gerhard Stöbich <deb2001-github@yahoo.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
2024-10-04 10:20:16 +02:00
Khafra
be2fe4b249
events: allow null/undefined eventInitDict
...
PR-URL: https://github.com/nodejs/node/pull/54643
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: LiviaMedeiros <livia@cirno.name >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2024-10-04 10:20:15 +02:00
jazelly
f7c3b03759
lib: propagate aborted state to dependent signals before firing events
...
PR-URL: https://github.com/nodejs/node/pull/54826
Fixes: https://github.com/nodejs/node/issues/54466
Fixes: https://github.com/nodejs/node/issues/54601
Reviewed-By: James M Snell <jasnell@gmail.com >
2024-10-04 10:20:15 +02:00
Pietro Marchini
4b962a78c7
test_runner: replace ansi clear with ansi reset
...
PR-URL: https://github.com/nodejs/node/pull/55013
Fixes: https://github.com/nodejs/node/issues/55009
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
2024-10-04 10:20:14 +02:00
Joyee Cheung
06957ff355
module: implement flushCompileCache()
...
This implements an API for users to intentionally flush the
accumulated compile cache instead of waiting until process
shutdown. It may be useful for application that loads dependencies
first and then either reload itself in other instances, or spawning
other instances that load an overlapping set of its dependencies -
in this case its useful to flush the cache early instead of waiting
until the shutdown of itself.
Currently flushing is triggered by either process
shutdown or user requests. In the future we should simply start the
writes right after module loading on a separate thread, and this method
only blocks until all the pending writes (if any) on the other thread
are finished. In that case, the off-thread writes should finish long
before any attempt of flushing is made so the method would then only
incur a negligible overhead from thread synchronization.
PR-URL: https://github.com/nodejs/node/pull/54971
Fixes: https://github.com/nodejs/node/issues/54770
Fixes: https://github.com/nodejs/node/issues/54465
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2024-10-04 10:20:13 +02:00
Chemi Atlow
d7c708aec5
test_runner: add support for coverage via run()
...
PR-URL: https://github.com/nodejs/node/pull/53937
Fixes: https://github.com/nodejs/node/issues/53867
Refs: https://github.com/nodejs/node/issues/53924
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2024-10-04 10:20:12 +02:00
Marco Ippolito
93c6c90219
test_runner: support typescript module mocking
...
PR-URL: https://github.com/nodejs/node/pull/54878
Fixes: https://github.com/nodejs/node/issues/54428
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: Erick Wendel <erick.workspace@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
Reviewed-By: Paolo Insogna <paolo@cowtech.it >
2024-10-04 10:20:10 +02:00
Antoine du Hamel
1d169764db
module: report unfinished TLA in ambiguous modules
...
PR-URL: https://github.com/nodejs/node/pull/54980
Fixes: https://github.com/nodejs/node/issues/54931
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2024-10-04 10:20:09 +02:00
Antoine du Hamel
fc90d7c63a
worker: handle --input-type more consistently
...
PR-URL: https://github.com/nodejs/node/pull/54979
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
2024-10-04 10:20:09 +02:00
Yagiz Nizipli
9abd1c7288
zlib: remove prototype primordials usage
...
# Conflicts:
# lib/zlib.js
PR-URL: https://github.com/nodejs/node/pull/54695
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: Robert Nagy <ronagy@icloud.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ruy Adorno <ruy@vlt.sh >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Matthew Aitken <maitken033380023@gmail.com >
2024-10-04 10:20:09 +02:00
dependabot[bot]
31f0ef6ea3
tools: bump the eslint group in /tools/eslint with 7 updates
...
Bumps the eslint group in /tools/eslint with 7 updates:
| Package | From | To |
| --- | --- | --- |
| `@babel/core` | `7.24.9` | `7.25.2` |
| `@babel/eslint-parser` | `7.25.0` | `7.25.1` |
| `@babel/plugin-syntax-import-attributes` | `7.24.7` | `7.25.6` |
| `@stylistic/eslint-plugin-js` | `2.4.0` | `2.7.2` |
| `eslint` | `9.8.0` | `9.9.1` |
| `eslint-plugin-jsdoc` | `48.8.3` | `50.2.2` |
| `globals` | `15.8.0` | `15.9.0` |
Signed-off-by: dependabot[bot] <support@github.com >
PR-URL: https://github.com/nodejs/node/pull/54821
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2024-10-04 10:20:09 +02:00
Pietro Marchini
1daec9a63f
test_runner: avoid coverage report partial file names
...
Co-author: Medhansh404 <21ucs126@lnmiit.ac.in >
PR-URL: https://github.com/nodejs/node/pull/54379
Fixes: https://github.com/nodejs/node/issues/51299
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
2024-10-04 10:20:08 +02:00
Khafra
cb47e169a0
events: return currentTarget when dispatching
...
PR-URL: https://github.com/nodejs/node/pull/54642
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Mattias Buelens <mattias@buelens.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
Reviewed-By: James M Snell <jasnell@gmail.com >
2024-10-04 10:20:07 +02:00
Wiyeong Seo
90cce6ec7c
path: remove repetitive conditional operator in posix.resolve
...
PR-URL: https://github.com/nodejs/node/pull/54835
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2024-10-04 10:20:07 +02:00
Trivikram Kamat
3300d5990f
os: use const with early return for path
...
PR-URL: https://github.com/nodejs/node/pull/54959
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Jake Yuesong Li <jake.yuesong@gmail.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2024-10-04 10:20:05 +02:00
Andrew Moon
349d2ed07b
crypto: add Date fields for validTo and validFrom
...
Added equivalent fields to `X509Certificate` in Date form.
PR-URL: https://github.com/nodejs/node/pull/54159
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Tim Perry <pimterry@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Richard Lau <rlau@redhat.com >
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com >
2024-10-04 10:20:05 +02:00
Joyee Cheung
c89c93496d
module: refator ESM loader for adding future synchronous hooks
...
This lays the foundation for supporting synchronous hooks proposed
in https://github.com/nodejs/loaders/pull/198 for ESM.
- Corrects and adds several JSDoc comments for internal functions
of the ESM loader, as well as explaining how require() for
import CJS work in the special resolve/load paths. This doesn't
consolidate it with import in require(esm) yet due to caching
differences, which is left as a TODO.
- The moduleProvider passed into ModuleJob is replaced as
moduleOrModulePromise, we call the translators directly in the
ESM loader and verify it right after loading for clarity.
- Reuse a few refactored out helpers for require(esm) in
getModuleJobForRequire().
PR-URL: https://github.com/nodejs/node/pull/54769
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2024-10-04 10:20:04 +02:00
Jordan Harband
397ae418db
lib: the REPL should survive deletion of Array.prototype methods
...
Specifically, `delete Array.prototype.lastIndexOf` immediately crashes
the REPL, as does deletion of a few other Array prototype methods.
PR-URL: https://github.com/nodejs/node/pull/31457
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
2024-10-04 10:20:04 +02:00
Joyee Cheung
108cef22e6
module: remove bogus assertion in CJS entrypoint handling with --import
...
The synchronous CJS translator can handle entrypoints now, this
can be hit when --import is used, so lift the bogus assertions and
added tests.
PR-URL: https://github.com/nodejs/node/pull/54592
Fixes: https://github.com/nodejs/node/issues/54577
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2024-10-04 10:20:04 +02:00
Marco Ippolito
67ecb10c78
module: fix discrepancy between .ts and .js
...
PR-URL: https://github.com/nodejs/node/pull/54461
Backport-PR-URL: https://github.com/nodejs/node/pull/54566
Fixes: https://github.com/nodejs/node/issues/54457
Reviewed-By: Paolo Insogna <paolo@cowtech.it >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Zeyu "Alex" Yang <himself65@outlook.com >
2024-09-18 09:24:49 +02:00