RafaelGSS
1f0ba0893f
2023-11-30, Version 21.3.0 (Current)
...
Notable changes:
crypto:
* update root certificates to NSS 3.95 (Node.js GitHub Bot) https://github.com/nodejs/node/pull/50805
fs:
* add c++ fast path for writeFileSync utf8 (CanadaHonk) https://github.com/nodejs/node/pull/49884
module:
* (SEMVER-MINOR) bootstrap module loaders in shadow realm (Chengzhong Wu) https://github.com/nodejs/node/pull/48655
* (SEMVER-MINOR) remove useCustomLoadersIfPresent flag (Chengzhong Wu) https://github.com/nodejs/node/pull/48655
src:
* (SEMVER-MINOR) add `--disable-warning` option (Ethan Arrowood) https://github.com/nodejs/node/pull/50661
* (SEMVER-MINOR) create per isolate proxy env template (Chengzhong Wu) https://github.com/nodejs/node/pull/48655
* (SEMVER-MINOR) create fs_dir per isolate properties (Chengzhong Wu) https://github.com/nodejs/node/pull/48655
* (SEMVER-MINOR) create worker per isolate properties (Chengzhong Wu) https://github.com/nodejs/node/pull/48655
* (SEMVER-MINOR) make process binding data weak (Chengzhong Wu) https://github.com/nodejs/node/pull/48655
PR-URL: https://github.com/nodejs/node/pull/50954
2023-11-29 10:09:20 -03:00
CanadaHonk
e59268a076
fs: add c++ fast path for writeFileSync utf8
...
PR-URL: https://github.com/nodejs/node/pull/49884
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io >
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2023-11-29 09:46:37 -03:00
CanadaHonk
483200f68f
fs: improve error performance for rmdirSync
...
PR-URL: https://github.com/nodejs/node/pull/49846
Refs: https://github.com/nodejs/performance/issues/106
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
2023-11-29 09:46:36 -03:00
Tobias Nießen
feb8ff9427
src: assert return value of BN_bn2binpad
...
Every other invocation of BN_bn2binpad checks the return value. For
safety and consistency, do so in RandomPrimeTraits::EncodeOutput()
as well.
PR-URL: https://github.com/nodejs/node/pull/50860
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2023-11-29 09:46:36 -03:00
Node.js GitHub Bot
8d3a1d8911
deps: update zlib to 1.2.13.1-motley-5daffc7
...
PR-URL: https://github.com/nodejs/node/pull/50803
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2023-11-29 09:46:36 -03:00
Michael Dawson
fd9195d750
src: fix coverity warning
...
- reduce copying by using std::move
Signed-off-by: Michael Dawson <midawson@redhat.com >
PR-URL: https://github.com/nodejs/node/pull/50846
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2023-11-29 09:46:36 -03:00
CanadaHonk
9dc4cde75b
fs: improve error perf of sync lstat+fstat
...
PR-URL: https://github.com/nodejs/node/pull/49868
Refs: https://github.com/nodejs/performance/issues/106
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2023-11-29 09:46:35 -03:00
Cheng Zhao
adcab85c0c
src: fix compatility with upcoming V8 12.1 APIs
...
PR-URL: https://github.com/nodejs/node/pull/50709
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Jiawen Geng <technicalcute@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2023-11-29 09:46:35 -03:00
Node.js GitHub Bot
d2c0dfb1b7
crypto: update root certificates to NSS 3.95
...
This is the certdata.txt[0] from NSS 3.95, released on 2023-11-16.
This is the version of NSS that will ship in Firefox 121 on
2023-12-19.
Certificates added:
- TrustAsia Global Root CA G3
- TrustAsia Global Root CA G4
- CommScope Public Trust ECC Root-01
- CommScope Public Trust ECC Root-02
- CommScope Public Trust RSA Root-01
- CommScope Public Trust RSA Root-02
Certificates removed:
- Autoridad de Certificacion Firmaprofesional CIF A62634068
[0] https://hg.mozilla.org/projects/nss/raw-file/NSS_3_95_RTM/lib/ckfw/builtins/certdata.txt
PR-URL: https://github.com/nodejs/node/pull/50805
Reviewed-By: Richard Lau <rlau@redhat.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2023-11-29 09:46:34 -03:00
79ef39b8c8
src: add --disable-warning option
...
Co-authored-by: Geoffrey Booth <webadmin@geoffreybooth.com >
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/50661
Fixes: https://github.com/nodejs/node/issues/30810
Fixes: https://github.com/nodejs/node/issues/47478
Fixes: https://github.com/nodejs/node/issues/46862
Fixes: https://github.com/nodejs/node/issues/40940
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Richard Lau <rlau@redhat.com >
2023-11-29 09:46:34 -03:00
Node.js GitHub Bot
221f02df6d
deps: update undici to 5.27.2
...
PR-URL: https://github.com/nodejs/node/pull/50813
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: Matthew Aitken <maitken033380023@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2023-11-29 09:46:33 -03:00
Keyhan Vakil
faf6a04ba6
src: add IsolateScopes before using isolates
...
The V8 API requires entering an isolate before using it. We were often
not doing this, which worked fine in practice. However when (multi-cage)
pointer compression is enabled, the correct isolate needs to be active
in order to decompress pointers correctly, otherwise it causes crashes.
Fix this by sprinkling in some calls to v8::Isolate::Scope::Scope where
they were missing.
This also introduces RAIIIsolateWithoutEntering which is used in
JSONParser to avoid otherwise exposing the Isolate::Scope outside of the
class.
Tested by compiling with `--experimental-enable-pointer-compression`
locally and running all tests.
Refs: https://github.com/nodejs/build/issues/3204#issuecomment-1790213488
Refs: https://bugs.chromium.org/p/v8/issues/detail?id=14292
PR-URL: https://github.com/nodejs/node/pull/50680
Refs: https://github.com/v8/v8/commit/475c8cdf9a951bb06da3084794a0f659f8ef36c2
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2023-11-29 09:46:33 -03:00
Michaël Zasso
eacf4ba485
src: iterate on import attributes array correctly
...
The array's length is supposed to be a multiple of two for dynamic
import callbacks.
Fixes: https://github.com/nodejs/node/issues/50700
PR-URL: https://github.com/nodejs/node/pull/50703
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Shelley Vohr <shelley.vohr@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2023-11-29 09:46:32 -03:00
Tobias Nießen
0fb35b6a67
src: avoid copying strings in FSPermission::Apply
...
The use of string_view and subsequent copying to a string was supposed
to be a minor optimization in 640a7918 , however, since 413c16e4 , no
string splitting occurs anymore. Therefore, we can simply pass around
some references instead of using string_view or copying strings.
Refs: https://github.com/nodejs/node/pull/48491
Refs: https://github.com/nodejs/node/pull/49047
PR-URL: https://github.com/nodejs/node/pull/50662
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2023-11-29 09:46:32 -03:00
Tobias Nießen
83ad272fa6
src: remove erroneous default argument in RadixTree
...
This default argument can never benefit any potential caller because any
call site that occurs after this definition will result in a compiler
error due to RadixTree::Lookup(const std::string_view&) now being an
ambiguous call target.
PR-URL: https://github.com/nodejs/node/pull/50736
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2023-11-29 09:46:32 -03:00
Joyee Cheung
aebe2fc702
perf_hooks: implement performance.now() with fast API calls
...
PR-URL: https://github.com/nodejs/node/pull/50492
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Bryan English <bryan@bryanenglish.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
2023-11-29 09:45:22 -03:00
Tobias Nießen
27a4f58640
permission: mark const functions as such
...
Otherwise, non-mutating functions such as is_tree_granted unnecessarily
require pointers to mutable data structures.
PR-URL: https://github.com/nodejs/node/pull/50705
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
2023-11-29 09:45:21 -03:00
Keyhan Vakil
2e8e237ce2
src: fix JSONParser leaking internal V8 scopes
...
JSONParser uses V8's JSON.parse (for now), meaning that its uses handles
and contexts. JSONParser was leaking its internal HandleScope and
Context::Scope.
Move the scope construction to the member functions to prevent those
scopes from leaking.
Refs: https://github.com/nodejs/node/pull/50680#discussion_r1390363367
PR-URL: https://github.com/nodejs/node/pull/50688
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2023-11-23 10:15:45 +01:00
Ardi Nugraha
0d3aa725cf
src: return error --env-file if file is not found
...
PR-URL: https://github.com/nodejs/node/pull/50588
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
2023-11-23 10:15:44 +01:00
Chengzhong Wu
c7a7493ca2
module: bootstrap module loaders in shadow realm
...
This bootstraps ESM loaders in the ShadowRealm with
`ShadowRealm.prototype.importValue` as its entry point and enables
loading ESM and CJS modules in the ShadowRealm. The module is imported
without a parent URL and resolved with the current process's working
directory.
PR-URL: https://github.com/nodejs/node/pull/48655
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2023-11-23 10:15:44 +01:00
legendecas
aadff07e59
src: create per isolate proxy env template
...
PR-URL: https://github.com/nodejs/node/pull/48655
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2023-11-23 10:15:43 +01:00
legendecas
91aa9dd23a
src: create fs_dir per isolate properties
...
PR-URL: https://github.com/nodejs/node/pull/48655
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2023-11-23 10:15:43 +01:00
legendecas
5c5834190a
src: create worker per isolate properties
...
PR-URL: https://github.com/nodejs/node/pull/48655
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2023-11-23 10:15:43 +01:00
legendecas
4a1ce45181
src: make process binding data weak
...
Avoid the realm being strongly referenced by the process binding data.
PR-URL: https://github.com/nodejs/node/pull/48655
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2023-11-23 10:15:43 +01:00
Gabriel Schulhof
673de300b4
node-api: factor out common code into macros
...
* Create macro for checking new string arguments.
* Create macro for combining env check and inside-gc check.
PR-URL: https://github.com/nodejs/node/pull/50664
Reviewed-By: Vladimir Morozov <vmorozov@microsoft.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2023-11-23 10:15:42 +01:00
Tobias Nießen
8746073664
src: avoid silent coercion to signed/unsigned int
...
Be accurate about signedness and bit widths.
PR-URL: https://github.com/nodejs/node/pull/50663
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2023-11-23 10:15:42 +01:00
Deokjin Kim
57587de1fa
src: handle errors from uv_pipe_connect2()
...
We need to handle errors from uv_pipe_connect2()
because return type is `int`.
Fixes: https://github.com/nodejs/node/issues/50652
Refs: https://github.com/nodejs/node/pull/49667
Refs: https://github.com/libuv/libuv/pull/4030
PR-URL: https://github.com/nodejs/node/pull/50657
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: theanarkh <theratliter@gmail.com >
2023-11-23 10:15:42 +01:00
Michaël Zasso
ae93ed24ae
Working on v21.2.1
...
PR-URL: https://github.com/nodejs/node/pull/50681
2023-11-14 18:58:15 +01:00
Michaël Zasso
13b266f457
2023-11-14, Version 21.2.0 (Current)
...
Notable changes:
doc:
* add MrJithil to collaborators (Jithil P Ponnan) https://github.com/nodejs/node/pull/50666
* add Ethan-Arrowood as a collaborator (Ethan Arrowood) https://github.com/nodejs/node/pull/50393
esm:
* (SEMVER-MINOR) add import.meta.dirname and import.meta.filename (James Sumners) https://github.com/nodejs/node/pull/48740
fs:
* add stacktrace to fs/promises (翠 / green) https://github.com/nodejs/node/pull/49849
lib:
* (SEMVER-MINOR) add `--no-experimental-global-navigator` CLI flag (Antoine du Hamel) https://github.com/nodejs/node/pull/50562
* (SEMVER-MINOR) add navigator.language & navigator.languages (Aras Abbasi) https://github.com/nodejs/node/pull/50303
* (SEMVER-MINOR) add navigator.platform (Aras Abbasi) https://github.com/nodejs/node/pull/50385
stream:
* (SEMVER-MINOR) add support for `deflate-raw` format to webstreams compression (Damian Krzeminski) https://github.com/nodejs/node/pull/50097
* use Array for Readable buffer (Robert Nagy) https://github.com/nodejs/node/pull/50341
* optimize creation (Robert Nagy) https://github.com/nodejs/node/pull/50337
test_runner:
* (SEMVER-MINOR) adds built in lcov reporter (Phil Nash) https://github.com/nodejs/node/pull/50018
* (SEMVER-MINOR) add Date to the supported mock APIs (Lucas Santos) https://github.com/nodejs/node/pull/48638
test_runner, cli:
* (SEMVER-MINOR) add --test-timeout flag (Shubham Pandey) https://github.com/nodejs/node/pull/50443
PR-URL: https://github.com/nodejs/node/pull/50681
2023-11-14 09:25:06 +01:00
Cheng Zhao
b9f3613908
build: add GN build files
...
PR-URL: https://github.com/nodejs/node/pull/47637
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2023-11-14 09:18:03 +01:00
Node.js GitHub Bot
5073a3e16d
deps: update base64 to 0.5.1
...
PR-URL: https://github.com/nodejs/node/pull/50629
Fixes: https://github.com/nodejs/node/issues/50561
Fixes: https://github.com/nodejs/node/pull/45091
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Richard Lau <rlau@redhat.com >
2023-11-14 09:18:03 +01:00
Antoine du Hamel
6dbb280733
lib: add --no-experimental-global-navigator CLI flag
...
PR-URL: https://github.com/nodejs/node/pull/50562
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Richard Lau <rlau@redhat.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
2023-11-14 09:17:59 +01:00
Shubham Pandey
05e8b6ef20
test_runner, cli: add --test-timeout flag
...
PR-URL: https://github.com/nodejs/node/pull/50443
Fixes: https://github.com/nodejs/node/issues/50431
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: Raz Luvaton <rluvaton@gmail.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
2023-11-14 09:17:58 +01:00
Joyee Cheung
b740324f7c
src: use v8::Isolate::TryGetCurrent() in DumpJavaScriptBacktrace()
...
It was using Isolate::GetCurrent() which DCHECK on nullptr, even
though what we wanted was to return early if it is nullptr.
PR-URL: https://github.com/nodejs/node/pull/50518
Refs: https://github.com/nodejs/node/pull/50242
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
Reviewed-By: Juan José Arboleda <soyjuanarbol@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2023-11-14 09:17:55 +01:00
Joyee Cheung
6e20e083dd
src: print more information in C++ assertions
...
This patch:
- Introduce an internal GetCurrentStackTrace() utility to get the
current JavaScript stack trace with best effort.
- Indent the assertion message so that is separated from the native
stack trace for redability
- Print the JS stack trace when it's available
Previoiusly the abort message looks like this:
```
out/Release/node[24458]: ../../src/node_file.cc:2008:void node::fs::Ope
n(const FunctionCallbackInfo<v8::Value> &): Assertion `(argc) >= (3)' f
ailed.
1: 0x1043fb9a4 node::Abort() [node]
2: 0x1043fb6e4 node::PrintCaughtException(v8::Isolate*, v8::Local<v8::
Context>, v8::TryCatch const&) [node]
3: 0x104407708 node::fs::Open(v8::FunctionCallbackInfo<v8::Value> cons
t&) [node]
4: 0x104611e74 v8::internal::MaybeHandle<v8::internal::Object> v8::int
ernal::(anonymous namespace)::HandleApiCallHelper<false>(v8::internal::
Isolate*, v8::internal::Handle<v8::internal::HeapObject
>, v8::internal::Handle<v8::internal::FunctionTemplateInfo>, v8::intern
al::Handle<v8::internal::Object>, unsigned long*, int) [node
]
5: 0x1046116c8 v8::internal::Builtin_HandleApiCall(int, unsigned long*
, v8::internal::Isolate*) [node]
6: 0x104e9cb24 Builtins_CEntry_Return1_ArgvOnStack_BuiltinExit [node]
7: 0x104e143e4 Builtins_InterpreterEntryTrampoline [node]
8: 0x104e1250c Builtins_JSEntryTrampoline [node]
9: 0x104e121f4 Builtins_JSEntry [node]
10: 0x1046ed54c v8::internal::(anonymous namespace)::Invoke(v8::interna
l::Isolate*, v8::internal::(anonymous namespace)::InvokeParams const&)
[node]
11: 0x1046edb60 v8::internal::Execution::CallScript(v8::internal::Isola
te*, v8::internal::Handle<v8::internal::JSFunction>, v8::internal::Hand
le<v8::internal::Object>, v8::internal::Handle<v8::in
ternal::Object>) [node]
12: 0x1045a9fa0 v8::Script::Run(v8::Local<v8::Context>, v8::Local<v8::D
ata>) [node]
13: 0x1043efb68 node::contextify::ContextifyScript::EvalMachine(v8::Loc
al<v8::Context>, node::Environment*, long long, bool, bool, bool, v8::M
icrotaskQueue*, v8::FunctionCallbackInfo<v8::Value> const&) [node
]
14: 0x1043ef3e0 node::contextify::ContextifyScript::RunInContext(v8::Fu
nctionCallbackInfo<v8::Value> const&) [node]
15: 0x104611e74 v8::internal::MaybeHandle<v8::internal::Object> v8::int
ernal::(anonymous namespace)::HandleApiCallHelper<false>(v8::internal::
Isolate*, v8::internal::Handle<v8::internal::HeapObject>
, v8::internal::Handle<v8::internal::FunctionTemplateInfo>, v8::interna
l::Handle<v8::internal::Object>, unsigned long*, int) [node
]
16: 0x1046116c8 v8::internal::Builtin_HandleApiCall(int, unsigned long*
, v8::internal::Isolate*) [node]
17: 0x104e9cb24 Builtins_CEntry_Return1_ArgvOnStack_BuiltinExit [node]
18: 0x104e143e4 Builtins_InterpreterEntryTrampoline [node]
19: 0x104e143e4 Builtins_InterpreterEntryTrampoline [node]
20: 0x104e143e4 Builtins_InterpreterEntryTrampoline [node]
21: 0x104e143e4 Builtins_InterpreterEntryTrampoline [node]
22: 0x104e143e4 Builtins_InterpreterEntryTrampoline [node]
23: 0x104e143e4 Builtins_InterpreterEntryTrampoline [node]
24: 0x104e143e4 Builtins_InterpreterEntryTrampoline [node]
25: 0x104e1250c Builtins_JSEntryTrampoline [node]
26: 0x104e121f4 Builtins_JSEntry [node]
27: 0x1046ed54c v8::internal::(anonymous namespace)::Invoke(v8::interna
l::Isolate*, v8::internal::(anonymous namespace)::InvokeParams const&)
[node]
28: 0x1046ecdc8 v8::internal::Execution::Call(v8::internal::Isolate*, v
8::internal::Handle<v8::internal::Object>, v8::internal::Handle<v8::int
ernal::Object>, int, v8::internal::Handle<v
8::internal::Object>*) [node]
29: 0x1045be23c v8::Function::Call(v8::Local<v8::Context>, v8::Local<v8
::Value>, int, v8::Local<v8::Value>*) [node]
30: 0x1043df704 node::builtins::BuiltinLoader::CompileAndCall(v8::Local
<v8::Context>, char const*, node::Realm*) [node]
31: 0x10446f2d4 node::Realm::ExecuteBootstrapper(char const*) [node]
32: 0x1043c3378 node::StartExecution(node::Environment*, std::__1::func
tion<v8::MaybeLocal<v8::Value> (node::StartExecutionCallbackInfo const&
)>) [node]
33: 0x10432dc28 node::LoadEnvironment(node::Environment*, std::__1::fun
ction<v8::MaybeLocal<v8::Value> (node::StartExecutionCallbackInfo const
&)>) [node]
34: 0x10443d1f4 node::NodeMainInstance::Run(node::ExitCode*, node::Envi
ronment*) [node]
35: 0x10443cfd0 node::NodeMainInstance::Run() [node]
36: 0x1043c5d18 node::Start(int, char**) [node]
37: 0x19a027f28 start [/usr/lib/dyld]
[1] 24458 abort out/Release/node -p "process.binding('fs').open
()"
```
Now it looks like this:
```
# out/Release/node[24856]: void node::fs::Open(const FunctionCallbac
kInfo<v8::Value> &) at ../../src/node_file.cc:2008
# Assertion failed: (argc) >= (3)
----- Native stack trace -----
1: 0x1001efe64 node::Abort() [node]
2: 0x1001efba4 node::PrintCaughtException(v8::Isolate*, v8::Local<v8::
Context>, v8::TryCatch const&) [node]
3: 0x1001fb868 node::fs::Open(v8::FunctionCallbackInfo<v8::Value> cons
t&) [node]
4: 0x100405fd4 v8::internal::MaybeHandle<v8::internal::Object> v8::int
ernal::(anonymous namespace)::HandleApiCallHelper<false>(v8::internal::
Isolate*, v8::internal::Handle<v8::internal::HeapObject
>, v8::internal::Handle<v8::internal::FunctionTemplateInfo>, v8::intern
al::Handle<v8::internal::Object>, unsigned long*, int) [node
]
5: 0x100405828 v8::internal::Builtin_HandleApiCall(int, unsigned long*
, v8::internal::Isolate*) [node]
6: 0x100c90b24 Builtins_CEntry_Return1_ArgvOnStack_BuiltinExit [node]
7: 0x100c083e4 Builtins_InterpreterEntryTrampoline [node]
8: 0x100c0650c Builtins_JSEntryTrampoline [node]
9: 0x100c061f4 Builtins_JSEntry [node]
10: 0x1004e16ac v8::internal::(anonymous namespace)::Invoke(v8::interna
l::Isolate*, v8::internal::(anonymous namespace)::InvokeParams const&)
[node]
11: 0x1004e1cc0 v8::internal::Execution::CallScript(v8::internal::Isola
te*, v8::internal::Handle<v8::internal::JSFunction>, v8::internal::Hand
le<v8::internal::Object>, v8::internal::Handle<v8::in
ternal::Object>) [node]
12: 0x10039e100 v8::Script::Run(v8::Local<v8::Context>, v8::Local<v8::D
ata>) [node]
13: 0x1001e4028 node::contextify::ContextifyScript::EvalMachine(v8::Loc
al<v8::Context>, node::Environment*, long long, bool, bool, bool, v8::M
icrotaskQueue*, v8::FunctionCallbackInfo<v8::Value> const&) [node
]
14: 0x1001e38a0 node::contextify::ContextifyScript::RunInContext(v8::Fu
nctionCallbackInfo<v8::Value> const&) [node]
15: 0x100405fd4 v8::internal::MaybeHandle<v8::internal::Object> v8::int
ernal::(anonymous namespace)::HandleApiCallHelper<false>(v8::internal::
Isolate*, v8::internal::Handle<v8::internal::HeapObject>
, v8::internal::Handle<v8::internal::FunctionTemplateInfo>, v8::interna
l::Handle<v8::internal::Object>, unsigned long*, int) [node
]
16: 0x100405828 v8::internal::Builtin_HandleApiCall(int, unsigned long*
, v8::internal::Isolate*) [node]
17: 0x100c90b24 Builtins_CEntry_Return1_ArgvOnStack_BuiltinExit [node]
18: 0x100c083e4 Builtins_InterpreterEntryTrampoline [node]
19: 0x100c083e4 Builtins_InterpreterEntryTrampoline [node]
20: 0x100c083e4 Builtins_InterpreterEntryTrampoline [node]
21: 0x100c083e4 Builtins_InterpreterEntryTrampoline [node]
22: 0x100c083e4 Builtins_InterpreterEntryTrampoline [node]
23: 0x100c083e4 Builtins_InterpreterEntryTrampoline [node]
24: 0x100c083e4 Builtins_InterpreterEntryTrampoline [node]
25: 0x100c0650c Builtins_JSEntryTrampoline [node]
26: 0x100c061f4 Builtins_JSEntry [node]
27: 0x1004e16ac v8::internal::(anonymous namespace)::Invoke(v8::interna
l::Isolate*, v8::internal::(anonymous namespace)::InvokeParams const&)
[node]
28: 0x1004e0f28 v8::internal::Execution::Call(v8::internal::Isolate*, v
8::internal::Handle<v8::internal::Object>, v8::internal::Handle<v8::int
ernal::Object>, int, v8::internal::Handle<v
8::internal::Object>*) [node]
29: 0x1003b239c v8::Function::Call(v8::Local<v8::Context>, v8::Local<v8
::Value>, int, v8::Local<v8::Value>*) [node]
30: 0x1001d3bc4 node::builtins::BuiltinLoader::CompileAndCall(v8::Local
<v8::Context>, char const*, node::Realm*) [node]
31: 0x100263434 node::Realm::ExecuteBootstrapper(char const*) [node]
32: 0x1001b7838 node::StartExecution(node::Environment*, std::__1::func
tion<v8::MaybeLocal<v8::Value> (node::StartExecutionCallbackInfo const&
)>) [node]
33: 0x100121c28 node::LoadEnvironment(node::Environment*, std::__1::fun
ction<v8::MaybeLocal<v8::Value> (node::StartExecutionCallbackInfo const
&)>) [node]
34: 0x100231354 node::NodeMainInstance::Run(node::ExitCode*, node::Envi
ronment*) [node]
35: 0x100231130 node::NodeMainInstance::Run() [node]
36: 0x1001ba1d8 node::Start(int, char**) [node]
37: 0x19a027f28 start [/usr/lib/dyld]
----- JavaScript stack trace -----
1: [eval]:1:23
2: runScriptInThisContext (node:internal/vm:144:10)
3: node:internal/process/execution:109:14
4: [eval]-wrapper:6:24
5: runScript (node:internal/process/execution:92:62)
6: evalScript (node:internal/process/execution:123:10)
7: node:internal/main/eval_string:51:3
[1] 24856 abort out/Release/node -p "process.binding('fs').open
()"
```
PR-URL: https://github.com/nodejs/node/pull/50242
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
2023-11-14 09:17:51 +01:00
Node.js GitHub Bot
57bfe53095
deps: update zlib to 1.2.13.1-motley-dfc48fc
...
PR-URL: https://github.com/nodejs/node/pull/50456
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2023-11-14 09:17:50 +01:00
Chengzhong Wu
773cfa59bb
vm: allow dynamic import with a referrer realm
...
A referrer can be a Script Record, a Cyclic Module Record, or a Realm
Record as defined in https://tc39.es/ecma262/#sec-HostLoadImportedModule .
Add support for dynamic import calls with a realm as the referrer and
allow specifying an `importModuleDynamically` callback in
`vm.createContext`.
PR-URL: https://github.com/nodejs/node/pull/50360
Refs: https://github.com/nodejs/node/issues/49726
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2023-11-14 09:17:50 +01:00
Node.js GitHub Bot
28453ff966
deps: update acorn to 8.11.2
...
PR-URL: https://github.com/nodejs/node/pull/50460
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2023-11-14 09:17:48 +01:00
Node.js GitHub Bot
0a793a2566
deps: update undici to 5.27.0
...
PR-URL: https://github.com/nodejs/node/pull/50463
Reviewed-By: Matthew Aitken <maitken033380023@gmail.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2023-11-14 09:17:48 +01:00
Tobias Nießen
9f55dfc266
src: hide node::credentials::HasOnly outside unit
...
The function is not declared anywhere else and should not be visible
outside the compilation unit.
PR-URL: https://github.com/nodejs/node/pull/50450
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
2023-11-14 09:17:47 +01:00
Khafra
4eb74a2c24
src: readiterable entries may be empty
...
fixup
PR-URL: https://github.com/nodejs/node/pull/50398
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
Reviewed-By: Debadree Chatterjee <debadree333@gmail.com >
2023-11-11 20:38:27 +01:00
Michael Dawson
7c35055c8e
permission: address coverity warning
...
The latest version of coverity has suggestions on how
to improve formance. Address one of these suggestions.
Signed-off-by: Michael Dawson <midawson@redhat.com >
PR-URL: https://github.com/nodejs/node/pull/50215
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
2023-11-11 20:38:26 +01:00
Yagiz Nizipli
67cbe1b80f
fs,url: move FromNamespacedPath to node_url
...
PR-URL: https://github.com/nodejs/node/pull/50090
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com >
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
2023-11-11 20:38:24 +01:00
Yagiz Nizipli
b4db32e9cb
fs,url: refactor FileURLToPath method
...
PR-URL: https://github.com/nodejs/node/pull/50090
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com >
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
2023-11-11 20:38:24 +01:00
Yagiz Nizipli
4345ee2ede
fs,url: move FileURLToPath to node_url
...
PR-URL: https://github.com/nodejs/node/pull/50090
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com >
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
2023-11-11 20:38:23 +01:00
Joyee Cheung
5b453d45d6
src: implement structuredClone in native
...
Simplify the implementation by implementing it directly in C++.
This improves performance and also makes structuredClone supported
in custom snapshots.
PR-URL: https://github.com/nodejs/node/pull/50330
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com >
2023-11-11 20:38:22 +01:00
Daniel Lemire
f1d79b3cbb
src: use find instead of char-by-char in FromFilePath()
...
PR-URL: https://github.com/nodejs/node/pull/50288
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
2023-11-11 20:37:45 +01:00
Jithil P Ponnan
541bdf1e92
src: add commit hash shorthand in zlib version
...
src: add commit hash shorthand in zlib version
PR-URL: https://github.com/nodejs/node/pull/50158
Fixes: https://github.com/nodejs/node/issues/50139
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
2023-11-11 20:37:42 +01:00
Michaël Zasso
dcbddf05f3
Working on v21.1.1
...
PR-URL: https://github.com/nodejs/node/pull/50335
2023-10-24 15:11:08 +02:00
Michaël Zasso
f4e5bebe7d
2023-10-24, Version 21.1.0 (Current)
...
Notable changes:
doc:
* add H4ad to collaborators (Vinícius Lourenço) https://github.com/nodejs/node/pull/50217
esm:
* (SEMVER-MINOR) detect ESM syntax in ambiguous JavaScript (Geoffrey Booth) https://github.com/nodejs/node/pull/50096
fs:
* (SEMVER-MINOR) add flush option to appendFile() functions (Colin Ihrig) https://github.com/nodejs/node/pull/50095
lib:
* (SEMVER-MINOR) add `navigator.userAgent` (Yagiz Nizipli) https://github.com/nodejs/node/pull/50200
stream:
* (SEMVER-MINOR) allow pass stream class to `stream.compose` (Alex Yang) https://github.com/nodejs/node/pull/50187
* call helper function from push and unshift (Raz Luvaton) https://github.com/nodejs/node/pull/50173
PR-URL: https://github.com/nodejs/node/pull/50335
2023-10-24 11:48:05 +02:00