@yao-pkg/pkg-fetch 3.5.20 → 3.5.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -21,37 +21,37 @@
21
21
  "node-v16.20.2-win-arm64": "7514915e02aedfbdc9f87ede04f1f251b014e312e3e184d5b94b42aeb28c2485",
22
22
  "node-v16.20.2-win-x64": "272729724993ce07b37d328718a0152e50ec5c9d27aa972975c09b75604c0dca",
23
23
  "node-v16.20.2-macos-arm64": "3d04eb7ddd8b614b888eeb1caa6e64a068b665ab4a26dd064051973ae5842a85",
24
- "node-v18.20.6-alpine-arm64": "281930d5ef29947b4753beacebfb73a40999434d3bd00e433a949c4f5bf0930c",
25
- "node-v18.20.6-alpine-x64": "8ba2556f12778970132aa53c0fb0f1fe656e2571c322ea062fd0ac7183f7323c",
26
- "node-v18.20.6-linux-arm64": "59dd11b5b46cea5be603f81fff06a5d2b2ffe64d91b98bf38cef7d806de3287f",
27
- "node-v18.20.6-linux-x64": "8970839230fee12effe6e67760d5853b51de2bba2c76eed9aff4aa568584d6a3",
28
- "node-v18.20.6-linuxstatic-arm64": "660ba7ac0cd04d55dfe82f2c1d19610fe99bab22c6081ea9efcb7bd9a66cffd8",
29
- "node-v18.20.6-linuxstatic-armv7": "9aeecde83542eb8483266558268c5d8347f28b829ed51272aa66f0b1daeeb90e",
30
- "node-v18.20.6-linuxstatic-x64": "06a576aa867ad91c05cfd5686a1c68ff5289ead50016bef09f8aa1d9cb010e90",
31
- "node-v18.20.6-macos-arm64": "1e40e96cf8973b37cffaca273e32fd813e02d1a4489b0e2e7f5bef6c61d31122",
32
- "node-v18.20.6-macos-x64": "80a39eb08e1c84e3b67896150744ab7d4c1f3e59032ecd02275d6decfb7bf11a",
33
- "node-v18.20.6-win-arm64": "28dba5ea277752cedd6bfffc102cc0a09b73a635e42d062a5b2f597a9e01a98c",
34
- "node-v18.20.6-win-x64": "7b6a456613ca09dacf0755118daa498965828261029640d009f224dcd96d1737",
35
- "node-v20.18.2-alpine-arm64": "17fe886df87970888c5bd858aa79846f7087219c6409e3c5c77f04322850efcb",
36
- "node-v20.18.2-alpine-x64": "9dc46c3cc2395d464a00f5f31d800007ff99dbf9fc6edd646a57cf0c68efe7c5",
37
- "node-v20.18.2-linux-arm64": "e69be4a9a1c90f21b278ae8265528b58f415a86d0a7acfe25a77a791237da79f",
38
- "node-v20.18.2-linux-x64": "c811a87d18fbbd3893848360b4ad0c8e48bf265146c7f1881f4dae5220866b88",
39
- "node-v20.18.2-linuxstatic-arm64": "4e1d20f80e684c237d2fac3ba155bef0b382dba6480d95107dd2ebd513612a37",
40
- "node-v20.18.2-linuxstatic-armv7": "1085e6e1b605ad4d5d8d5cfdcd86edc0cf5b63610ea2a446fa5c2a9b19fd832c",
41
- "node-v20.18.2-linuxstatic-x64": "367bdea6bcdc877f922d1b9438ad51dd1ef26d5a3dd601fca4723851ecde5692",
42
- "node-v20.18.2-macos-arm64": "92faed49ad7c38c6374f1f421266ea4a09ed8d9830baebc1a5bcf2f3d90f107b",
43
- "node-v20.18.2-macos-x64": "68f69f407965a15adc3bf58fdb052f455c0ab7c836883372e00d15f70cbc5c1b",
44
- "node-v20.18.2-win-arm64": "655fb0cd72e6547a78422914f895081c4176dfbc742cf88ab235c6c8c1e07275",
45
- "node-v20.18.2-win-x64": "fe7ea820ac3ef081bc97efeb67fc746272bb6d1eeca1690886356effbbd31350",
46
- "node-v22.13.1-alpine-arm64": "d19ce5d5686ebbe6eaf807422d6cd8dd97627b5755c6e479c66ff1d37829fcc0",
47
- "node-v22.13.1-alpine-x64": "dc8a8c04deaa3449177f564af945288e88726f945c62a79e107509f20cc00ea5",
48
- "node-v22.13.1-linux-arm64": "fcd0d05bb5002caf842be2293344dbe1c992ad341760bae2030d799e38fecceb",
49
- "node-v22.13.1-linux-x64": "3751bff61318b4f0b482577e4dce38ae9c2612330b45dae0a7aed6cdba692951",
50
- "node-v22.13.1-linuxstatic-arm64": "fa557f50d3803d9f30606cef376289b07cfb6109a932ed070ef280632e7476a7",
51
- "node-v22.13.1-linuxstatic-armv7": "bd13ee93bccf40d4ef596529bd0e0867de4a479d77e36d28961d3701cfab4c3b",
52
- "node-v22.13.1-linuxstatic-x64": "808e29d1c4171abd61594a42bf2192d796d65166acd55234be23db1900cd4ed9",
53
- "node-v22.13.1-macos-arm64": "f787ef3975dceb4422ae076de393714324fb496c16d9a4ec72fe1d736961b52c",
54
- "node-v22.13.1-macos-x64": "17e8418231185632bfec926af35be17cf077685721151219056b9cc96184aa66",
55
- "node-v22.13.1-win-arm64": "562fcaee12ae69c3f2a7e5cb346aee18e40602ce8cdd3d9d0129283e68f9e228",
56
- "node-v22.13.1-win-x64": "4d30d3898942abf63df8e9080a5aecf4c2d7849183004d567f9fbe7e3be5ccaa"
24
+ "node-v18.20.8-alpine-arm64": "c7f20847fbfd765517612647593c7767331a318d2b229ddac2b4afd7d13b78d0",
25
+ "node-v18.20.8-alpine-x64": "3b24c6f571681046a6ed1b42752b21a41e10e8c7ac19416b9571927cc10f4a49",
26
+ "node-v18.20.8-linux-arm64": "63f58415622e601d0febd4c6278656b6a69022def646cd6d8f3d01e9c32bf928",
27
+ "node-v18.20.8-linux-x64": "0121b3c810db3f5e47028f0b1e2294a1a52a2aa20923c037247e39c82be0f789",
28
+ "node-v18.20.8-linuxstatic-arm64": "ac03e112f9229126e62924f1fefbb44c54f5fbbb4827d5ffa6243d3b8e81dfa4",
29
+ "node-v18.20.8-linuxstatic-armv7": "4c96d99319e850887d01cb63500e34f5db3b64944b3644f4ed5c94ae2be5b625",
30
+ "node-v18.20.8-linuxstatic-x64": "16e25c30e3a4d03a18e21bcd41b6980c65f837425d485e3f5f68c8362bad0625",
31
+ "node-v18.20.8-macos-arm64": "d3f8f8966ceb4cea5447edacda9d2f151e97e06baf21a3fcba9d7a7e8470cee9",
32
+ "node-v18.20.8-macos-x64": "f2cf139bfe3501d39d22b48a069f9ceb24942b0cdc001a0bc30ea3a68fbcc6b3",
33
+ "node-v18.20.8-win-arm64": "dd56454cfc9292f047413657c8b997006f27ecda8cd7f7dd38acf8d22317e743",
34
+ "node-v18.20.8-win-x64": "4d45cdfbcba3de3f6c0ddcd78251179b9d04dd2fcb2dba2fb052940a2821eb39",
35
+ "node-v20.19.1-alpine-arm64": "5f019f7b90cf3c89bdb083c3bf54fced619ad1f17f1a62bc587126c76d224306",
36
+ "node-v20.19.1-alpine-x64": "79f887e112a4f8e333a8090cf418f1a2468ded24396dbbfb1d2613fffee4b642",
37
+ "node-v20.19.1-linux-arm64": "0cb29189500580da854a2f58f3aa615bf1c70a7cddbcd59c3d8dea68b114d9a0",
38
+ "node-v20.19.1-linux-x64": "ccb7f16a71402f20353a493a215fc5d87d7075b500dc1323a5611c32caf4ea6d",
39
+ "node-v20.19.1-linuxstatic-arm64": "4065d940a0d8445716b2dc6266b9563efe773aa868bb14e8cdefc571d248cfe7",
40
+ "node-v20.19.1-linuxstatic-armv7": "1e3d3c594065d1aa8ebf11ac977bfa1612a59f38242c907a49973c6a36a95d18",
41
+ "node-v20.19.1-linuxstatic-x64": "ea798bb7672a70becf3048393359f3a624f8bfd4c1df4ce5ee67cdb0c21310e2",
42
+ "node-v20.19.1-macos-arm64": "67c9e9fdb947104d1d456c1634b3fb2fcfd1e5b963b3b33cadf44c2da995db79",
43
+ "node-v20.19.1-macos-x64": "299e685efaa92e61e2e09824407b93a937717db65ef5e6c1deb6f5d5b2b73e74",
44
+ "node-v20.19.1-win-arm64": "c8bddec0f4dd27b1eab788ffe7aadb63a5513cc49fab34b1b2adf286ce593836",
45
+ "node-v20.19.1-win-x64": "0137b69a69bc834694be27ee9317d0ac16bb33aa7c14610252cc85e9d03c756a",
46
+ "node-v22.15.1-alpine-arm64": "52197257ff837f306789aaa73257e0e5256829585c4e8e1a4a06385ec1915985",
47
+ "node-v22.15.1-alpine-x64": "85d772fdab79994fcc4a34ae5fcb5395bfa07b755d89cf8d32dcbeed6e1cbff2",
48
+ "node-v22.15.1-linux-arm64": "94eca862632857b3bab44d50656539e552a7046f41ca3e09103e0d1fc6866f38",
49
+ "node-v22.15.1-linux-x64": "bfd5417e798e0aada7c64eadaedca860fc668598646244a7abddb070539070ce",
50
+ "node-v22.15.1-linuxstatic-arm64": "4e98190b523d8df540d06e938ae90718b6cdeb59a13e6f2b72c90ebfe3bb1a21",
51
+ "node-v22.15.1-linuxstatic-armv7": "516dff8a2aebe784a74e51cb92aa487d45b0652a8aa2a8e351ce026b16416638",
52
+ "node-v22.15.1-linuxstatic-x64": "f18cecdaf8c118e5d466de2ac7ccef22aa5bc79f23136c824e203b403b246444",
53
+ "node-v22.15.1-macos-arm64": "77187bb631377edafaa666e3f76db4036c050108e64c139d283c4caa72bc9720",
54
+ "node-v22.15.1-macos-x64": "f642411e8a87f2127e62a019d0b87fd61aee8cc1c7b5d96119a0437bf031e2dc",
55
+ "node-v22.15.1-win-arm64": "7346edd7a1f191c5585f6e20c2e0c4d626b3f636cfda596c40a4189210ae661d",
56
+ "node-v22.15.1-win-x64": "fd78dc295241575f07a545385915bdf238d4fa9972679a984c5f82cd8361f005"
57
57
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yao-pkg/pkg-fetch",
3
- "version": "3.5.20",
3
+ "version": "3.5.22",
4
4
  "description": "Compiles and stores base binaries for pkg",
5
5
  "main": "lib-es5/index.js",
6
6
  "license": "MIT",
@@ -1,5 +1,5 @@
1
1
  diff --git node/common.gypi node/common.gypi
2
- index ec92c9df4c..8c1e94fca2 100644
2
+ index 1b45f13453..a5ad9e716c 100644
3
3
  --- node/common.gypi
4
4
  +++ node/common.gypi
5
5
  @@ -174,7 +174,7 @@
@@ -1,5 +1,5 @@
1
1
  diff --git node/common.gypi node/common.gypi
2
- index 1ece4f5e49..5107053bec 100644
2
+ index d3c17d47bc..7970af6ea4 100644
3
3
  --- node/common.gypi
4
4
  +++ node/common.gypi
5
5
  @@ -184,7 +184,7 @@
@@ -262,10 +262,10 @@ index 0000000000..a697294fdf
262
262
  + }());
263
263
  +}());
264
264
  diff --git node/lib/internal/modules/cjs/loader.js node/lib/internal/modules/cjs/loader.js
265
- index c284b39b1a..ce38f028e4 100644
265
+ index ebccdb2825..178299c752 100644
266
266
  --- node/lib/internal/modules/cjs/loader.js
267
267
  +++ node/lib/internal/modules/cjs/loader.js
268
- @@ -138,7 +138,7 @@ const {
268
+ @@ -141,7 +141,7 @@ const {
269
269
  const assert = require('internal/assert');
270
270
  const fs = require('fs');
271
271
  const path = require('path');
@@ -288,10 +288,10 @@ index 88c079d10d..a7eaca0574 100644
288
288
  const permission = require('internal/process/permission');
289
289
  const { kEmptyObject } = require('internal/util');
290
290
  diff --git node/lib/internal/process/pre_execution.js node/lib/internal/process/pre_execution.js
291
- index a05d284605..4186f13d60 100644
291
+ index 0bbabb80c2..5dd097b69e 100644
292
292
  --- node/lib/internal/process/pre_execution.js
293
293
  +++ node/lib/internal/process/pre_execution.js
294
- @@ -51,7 +51,11 @@ const {
294
+ @@ -50,7 +50,11 @@ const {
295
295
  },
296
296
  } = require('internal/v8/startup_snapshot');
297
297
 
@@ -303,17 +303,21 @@ index a05d284605..4186f13d60 100644
303
303
  return prepareExecution({
304
304
  expandArgv1,
305
305
  initializeModules,
306
- @@ -245,7 +249,8 @@ function patchProcessObject(expandArgv1) {
306
+ @@ -243,7 +247,12 @@ function patchProcessObject(expandArgv1) {
307
+ let mainEntry;
307
308
  // If requested, update process.argv[1] to replace whatever the user provided with the resolved absolute file path of
308
309
  // the entry point.
309
- if (expandArgv1 && process.argv[1] &&
310
- - !StringPrototypeStartsWith(process.argv[1], '-')) {
311
- + !StringPrototypeStartsWith(process.argv[1], '-') &&
312
- + process.argv[1] !== 'PKG_DUMMY_ENTRYPOINT') {
310
+ - if (expandArgv1 && process.argv[1] && process.argv[1][0] !== '-') {
311
+ + if (
312
+ + expandArgv1 &&
313
+ + process.argv[1] &&
314
+ + process.argv[1][0] !== '-' &&
315
+ + process.argv[1] !== 'PKG_DUMMY_ENTRYPOINT'
316
+ + ) {
313
317
  // Expand process.argv[1] into a full path.
314
318
  const path = require('path');
315
319
  try {
316
- @@ -741,6 +746,7 @@ function loadPreloadModules() {
320
+ @@ -739,6 +748,7 @@ function loadPreloadModules() {
317
321
  // For user code, we preload modules if `-r` is passed
318
322
  const preloadModules = getOptionValue('--require');
319
323
  if (preloadModules && preloadModules.length > 0) {
@@ -322,7 +326,7 @@ index a05d284605..4186f13d60 100644
322
326
  Module: {
323
327
  _preloadModules,
324
328
  diff --git node/lib/vm.js node/lib/vm.js
325
- index cb64404ef0..71209f89d3 100644
329
+ index a12e932d8d..931a996330 100644
326
330
  --- node/lib/vm.js
327
331
  +++ node/lib/vm.js
328
332
  @@ -98,6 +98,7 @@ class Script extends ContextifyScript {
@@ -360,10 +364,10 @@ index bb39a0cb42..5fa6cb65cc 100644
360
364
  parent_env_->AddCleanupHook([](void* data) {
361
365
  Environment* env = static_cast<Environment*>(data);
362
366
  diff --git node/src/node.cc node/src/node.cc
363
- index 9f6f8e53ab..ee8fa43f2f 100644
367
+ index 4ad2c8b804..ab6174fab6 100644
364
368
  --- node/src/node.cc
365
369
  +++ node/src/node.cc
366
- @@ -377,6 +377,8 @@ MaybeLocal<Value> StartExecution(Environment* env, StartExecutionCallback cb) {
370
+ @@ -389,6 +389,8 @@ MaybeLocal<Value> StartExecution(Environment* env, StartExecutionCallback cb) {
367
371
  return env->RunSnapshotDeserializeMain();
368
372
  }
369
373
 
@@ -372,7 +376,7 @@ index 9f6f8e53ab..ee8fa43f2f 100644
372
376
  if (env->worker_context() != nullptr) {
373
377
  return StartExecution(env, "internal/main/worker_thread");
374
378
  }
375
- @@ -601,14 +603,6 @@ static void PlatformInit(ProcessInitializationFlags::Flags flags) {
379
+ @@ -613,14 +615,6 @@ static void PlatformInit(ProcessInitializationFlags::Flags flags) {
376
380
  }
377
381
 
378
382
  if (!(flags & ProcessInitializationFlags::kNoDefaultSignalHandling)) {
@@ -388,10 +392,10 @@ index 9f6f8e53ab..ee8fa43f2f 100644
388
392
  }
389
393
 
390
394
  diff --git node/src/node_contextify.cc node/src/node_contextify.cc
391
- index 8951cd378a..746fb9939a 100644
395
+ index 7f82bca746..62705f04c5 100644
392
396
  --- node/src/node_contextify.cc
393
397
  +++ node/src/node_contextify.cc
394
- @@ -76,6 +76,7 @@ using v8::String;
398
+ @@ -79,6 +79,7 @@ using v8::String;
395
399
  using v8::Symbol;
396
400
  using v8::Uint32;
397
401
  using v8::UnboundScript;
@@ -399,7 +403,7 @@ index 8951cd378a..746fb9939a 100644
399
403
  using v8::Value;
400
404
  using v8::WeakCallbackInfo;
401
405
 
402
- @@ -816,13 +817,14 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
406
+ @@ -817,13 +818,14 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
403
407
  Local<ArrayBufferView> cached_data_buf;
404
408
  bool produce_cached_data = false;
405
409
  Local<Context> parsing_context = context;
@@ -416,7 +420,7 @@ index 8951cd378a..746fb9939a 100644
416
420
  CHECK(args[2]->IsNumber());
417
421
  line_offset = args[2].As<Int32>()->Value();
418
422
  CHECK(args[3]->IsNumber());
419
- @@ -843,6 +845,10 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
423
+ @@ -844,6 +846,10 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
420
424
  }
421
425
  CHECK(args[7]->IsSymbol());
422
426
  id_symbol = args[7].As<Symbol>();
@@ -427,7 +431,7 @@ index 8951cd378a..746fb9939a 100644
427
431
  }
428
432
 
429
433
  ContextifyScript* contextify_script =
430
- @@ -891,6 +897,10 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
434
+ @@ -892,6 +898,10 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
431
435
  ShouldNotAbortOnUncaughtScope no_abort_scope(env);
432
436
  Context::Scope scope(parsing_context);
433
437
 
@@ -438,7 +442,7 @@ index 8951cd378a..746fb9939a 100644
438
442
  MaybeLocal<UnboundScript> maybe_v8_script =
439
443
  ScriptCompiler::CompileUnboundScript(isolate, &source, compile_options);
440
444
 
441
- @@ -905,6 +915,11 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
445
+ @@ -906,6 +916,11 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
442
446
  return;
443
447
  }
444
448
 
@@ -450,7 +454,7 @@ index 8951cd378a..746fb9939a 100644
450
454
  contextify_script->script_.Reset(isolate, v8_script);
451
455
  contextify_script->script_.SetWeak();
452
456
  contextify_script->object()->SetInternalFieldForNodeCore(kUnboundScriptSlot,
453
- @@ -938,6 +953,10 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
457
+ @@ -939,6 +954,10 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
454
458
  .IsNothing())
455
459
  return;
456
460
 
@@ -572,10 +576,10 @@ index f66099a557..4048f6bd93 100644
572
576
  + return adjacent(c, nargv);
573
577
  +}
574
578
  diff --git node/src/node_options.cc node/src/node_options.cc
575
- index e325b082de..19b6782e29 100644
579
+ index 9d5accc3eb..8e3c304a13 100644
576
580
  --- node/src/node_options.cc
577
581
  +++ node/src/node_options.cc
578
- @@ -307,6 +307,7 @@ void Parse(
582
+ @@ -316,6 +316,7 @@ void Parse(
579
583
  // TODO(addaleax): Make that unnecessary.
580
584
 
581
585
  DebugOptionsParser::DebugOptionsParser() {
@@ -1,8 +1,8 @@
1
1
  diff --git node/common.gypi node/common.gypi
2
- index 62f26bb07d..1b576a65f4 100644
2
+ index 372409f4b0..5431580b6c 100644
3
3
  --- node/common.gypi
4
4
  +++ node/common.gypi
5
- @@ -187,7 +187,7 @@
5
+ @@ -189,7 +189,7 @@
6
6
  ['clang==1', {
7
7
  'lto': ' -flto ', # Clang
8
8
  }, {
@@ -28,7 +28,7 @@ index 7d3ab39bf8..67a48dee53 100644
28
28
  #else /* !((defined(_MSC_VER) && !defined(__clang__) && (defined(_M_ARM) || \
29
29
  (defined(_M_ARM64) && _MSC_VER < 1941))) || defined(WIN32)) */
30
30
  diff --git node/deps/ngtcp2/ngtcp2/lib/ngtcp2_ringbuf.c node/deps/ngtcp2/ngtcp2/lib/ngtcp2_ringbuf.c
31
- index 41446739bf..69c01b4f7f 100644
31
+ index 353afca4d4..dea944aed5 100644
32
32
  --- node/deps/ngtcp2/ngtcp2/lib/ngtcp2_ringbuf.c
33
33
  +++ node/deps/ngtcp2/ngtcp2/lib/ngtcp2_ringbuf.c
34
34
  @@ -33,10 +33,7 @@
@@ -315,13 +315,13 @@ index 0000000000..a697294fdf
315
315
  + }());
316
316
  +}());
317
317
  diff --git node/lib/internal/modules/cjs/loader.js node/lib/internal/modules/cjs/loader.js
318
- index 236b248404..a506611d2f 100644
318
+ index 33385fa792..61cb88dc0f 100644
319
319
  --- node/lib/internal/modules/cjs/loader.js
320
320
  +++ node/lib/internal/modules/cjs/loader.js
321
- @@ -229,12 +229,16 @@ function wrapModuleLoad(request, parent, isMain) {
322
- * @param {string} filename Absolute path to the file
323
- */
324
- function stat(filename) {
321
+ @@ -250,12 +250,16 @@ function stat(filename) {
322
+ // Guard against internal bugs where a non-string filename is passed in by mistake.
323
+ assert(typeof filename === 'string');
324
+
325
325
  + const origFilename = filename;
326
326
  filename = path.toNamespacedPath(filename);
327
327
  if (statCache !== null) {
@@ -337,13 +337,15 @@ index 236b248404..a506611d2f 100644
337
337
  // Only set cache when `internalModuleStat(internalFsBinding, filename)` succeeds.
338
338
  statCache.set(filename, result);
339
339
  diff --git node/lib/internal/modules/package_json_reader.js node/lib/internal/modules/package_json_reader.js
340
- index 9a9dcebb79..01fceafc31 100644
340
+ index 3c746fa0e7..c39ba93379 100644
341
341
  --- node/lib/internal/modules/package_json_reader.js
342
342
  +++ node/lib/internal/modules/package_json_reader.js
343
- @@ -80,14 +80,19 @@ function deserializePackageJSON(path, contents) {
343
+ @@ -105,17 +105,20 @@ const requiresJSONParse = (value) => (value !== undefined && (value[0] === '[' |
344
+ * @returns {PackageConfig}
345
+ */
344
346
  function read(jsonPath, { base, specifier, isESM } = kEmptyObject) {
345
- // This function will be called by both CJS and ESM, so we need to make sure
346
- // non-null attributes are converted to strings.
347
+ - // This function will be called by both CJS and ESM, so we need to make sure
348
+ - // non-null attributes are converted to strings.
347
349
  - const parsed = modulesBinding.readPackageJSON(
348
350
  - jsonPath,
349
351
  - isESM,
@@ -351,11 +353,13 @@ index 9a9dcebb79..01fceafc31 100644
351
353
  - specifier == null ? undefined : `${specifier}`,
352
354
  - );
353
355
  -
354
- - return deserializePackageJSON(jsonPath, parsed);
356
+ - const result = deserializePackageJSON(jsonPath, parsed);
357
+ -
355
358
  + const fs = require('fs');
359
+ + let result;
356
360
  + if (fs.existsSync(jsonPath)) {
357
361
  + const json = JSONParse(fs.readFileSync(jsonPath, { encoding: "utf8" }).trim());
358
- + return deserializePackageJSON(jsonPath, [
362
+ + result = deserializePackageJSON(jsonPath, [
359
363
  + json['name'],
360
364
  + json['main'],
361
365
  + json['type'],
@@ -363,13 +367,13 @@ index 9a9dcebb79..01fceafc31 100644
363
367
  + json['exports'],
364
368
  + ]);
365
369
  + } else {
366
- + return deserializePackageJSON(jsonPath, undefined);
370
+ + result = deserializePackageJSON(jsonPath, undefined);
367
371
  + }
368
- }
369
-
370
- /**
372
+ return {
373
+ __proto__: null,
374
+ ...result.data,
371
375
  diff --git node/lib/internal/process/pre_execution.js node/lib/internal/process/pre_execution.js
372
- index 5d67892bb8..5c4183cd30 100644
376
+ index d1c05d1717..c6c806f73c 100644
373
377
  --- node/lib/internal/process/pre_execution.js
374
378
  +++ node/lib/internal/process/pre_execution.js
375
379
  @@ -50,7 +50,11 @@ const {
@@ -394,7 +398,7 @@ index 5d67892bb8..5c4183cd30 100644
394
398
  // Expand process.argv[1] into a full path.
395
399
  const path = require('path');
396
400
  try {
397
- @@ -718,6 +723,7 @@ function loadPreloadModules() {
401
+ @@ -726,6 +731,7 @@ function loadPreloadModules() {
398
402
  // For user code, we preload modules if `-r` is passed
399
403
  const preloadModules = getOptionValue('--require');
400
404
  if (preloadModules && preloadModules.length > 0) {
@@ -425,10 +429,10 @@ index ae71080620..b05638de75 100644
425
429
  throw e; /* node-do-not-add-exception-line */
426
430
  }
427
431
  diff --git node/src/inspector_agent.cc node/src/inspector_agent.cc
428
- index bb39a0cb42..5fa6cb65cc 100644
432
+ index 7c63c22112..830c8be5ca 100644
429
433
  --- node/src/inspector_agent.cc
430
434
  +++ node/src/inspector_agent.cc
431
- @@ -766,11 +766,6 @@ bool Agent::Start(const std::string& path,
435
+ @@ -796,11 +796,6 @@ bool Agent::Start(const std::string& path,
432
436
  StartIoThreadAsyncCallback));
433
437
  uv_unref(reinterpret_cast<uv_handle_t*>(&start_io_thread_async));
434
438
  start_io_thread_async.data = this;
@@ -441,7 +445,7 @@ index bb39a0cb42..5fa6cb65cc 100644
441
445
  parent_env_->AddCleanupHook([](void* data) {
442
446
  Environment* env = static_cast<Environment*>(data);
443
447
  diff --git node/src/node.cc node/src/node.cc
444
- index f4365c0eda..f89c77fe44 100644
448
+ index a0f1deadfc..b8e241a5b4 100644
445
449
  --- node/src/node.cc
446
450
  +++ node/src/node.cc
447
451
  @@ -398,6 +398,8 @@ MaybeLocal<Value> StartExecution(Environment* env, StartExecutionCallback cb) {
@@ -469,10 +473,10 @@ index f4365c0eda..f89c77fe44 100644
469
473
  }
470
474
 
471
475
  diff --git node/src/node_contextify.cc node/src/node_contextify.cc
472
- index 5f4529262a..4ecfaf0513 100644
476
+ index 187ba89290..dbed6342a9 100644
473
477
  --- node/src/node_contextify.cc
474
478
  +++ node/src/node_contextify.cc
475
- @@ -85,6 +85,7 @@ using v8::Symbol;
479
+ @@ -86,6 +86,7 @@ using v8::Symbol;
476
480
  using v8::Uint32;
477
481
  using v8::UnboundScript;
478
482
  using v8::Value;
@@ -480,7 +484,7 @@ index 5f4529262a..4ecfaf0513 100644
480
484
 
481
485
  // The vm module executes code in a sandboxed environment with a different
482
486
  // global object than the rest of the code. This is achieved by applying
483
- @@ -981,13 +982,13 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
487
+ @@ -996,13 +997,13 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
484
488
  Local<ArrayBufferView> cached_data_buf;
485
489
  bool produce_cached_data = false;
486
490
  Local<Context> parsing_context = context;
@@ -497,7 +501,7 @@ index 5f4529262a..4ecfaf0513 100644
497
501
  CHECK(args[2]->IsNumber());
498
502
  line_offset = args[2].As<Int32>()->Value();
499
503
  CHECK(args[3]->IsNumber());
500
- @@ -1008,6 +1009,10 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
504
+ @@ -1023,6 +1024,10 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
501
505
  }
502
506
  CHECK(args[7]->IsSymbol());
503
507
  id_symbol = args[7].As<Symbol>();
@@ -508,7 +512,7 @@ index 5f4529262a..4ecfaf0513 100644
508
512
  }
509
513
 
510
514
  ContextifyScript* contextify_script =
511
- @@ -1055,6 +1060,10 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
515
+ @@ -1070,6 +1075,10 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
512
516
  ShouldNotAbortOnUncaughtScope no_abort_scope(env);
513
517
  Context::Scope scope(parsing_context);
514
518
 
@@ -519,7 +523,7 @@ index 5f4529262a..4ecfaf0513 100644
519
523
  MaybeLocal<UnboundScript> maybe_v8_script =
520
524
  ScriptCompiler::CompileUnboundScript(isolate, &source, compile_options);
521
525
 
522
- @@ -1069,6 +1078,12 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
526
+ @@ -1084,6 +1093,12 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
523
527
  return;
524
528
  }
525
529
 
@@ -532,7 +536,7 @@ index 5f4529262a..4ecfaf0513 100644
532
536
  contextify_script->script_.Reset(isolate, v8_script);
533
537
  contextify_script->script_.SetWeak();
534
538
  contextify_script->object()->SetInternalField(kUnboundScriptSlot, v8_script);
535
- @@ -1101,6 +1116,10 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
539
+ @@ -1116,6 +1131,10 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
536
540
  .IsNothing())
537
541
  return;
538
542
 
@@ -654,10 +658,10 @@ index f66099a557..4048f6bd93 100644
654
658
  + return adjacent(c, nargv);
655
659
  +}
656
660
  diff --git node/src/node_options.cc node/src/node_options.cc
657
- index a03daec2bd..d979b764db 100644
661
+ index 1444acd59d..f2eec6b35f 100644
658
662
  --- node/src/node_options.cc
659
663
  +++ node/src/node_options.cc
660
- @@ -312,6 +312,7 @@ void Parse(
664
+ @@ -317,6 +317,7 @@ void Parse(
661
665
  // TODO(addaleax): Make that unnecessary.
662
666
 
663
667
  DebugOptionsParser::DebugOptionsParser() {
@@ -1,7 +1,7 @@
1
1
  {
2
- "v22.13.1": ["node.v22.13.1.cpp.patch"],
3
- "v20.18.2": ["node.v20.18.2.cpp.patch"],
4
- "v18.20.6": ["node.v18.20.6.cpp.patch"],
2
+ "v22.15.1": ["node.v22.15.1.cpp.patch"],
3
+ "v20.19.1": ["node.v20.19.1.cpp.patch"],
4
+ "v18.20.8": ["node.v18.20.8.cpp.patch"],
5
5
  "v16.20.2": ["node.v16.20.2.cpp.patch"],
6
6
  "v14.21.3": ["node.v14.21.3.cpp.patch"],
7
7
  "v12.22.11": ["node.v12.22.11.cpp.patch"],