Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package nodejs20 for openSUSE:Factory 
checked in at 2023-09-10 13:09:33
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/nodejs20 (Old)
 and      /work/SRC/openSUSE:Factory/.nodejs20.new.1766 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "nodejs20"

Sun Sep 10 13:09:33 2023 rev:11 rq:1109713 version:20.6.0

Changes:
--------
--- /work/SRC/openSUSE:Factory/nodejs20/nodejs20.changes        2023-09-06 
18:57:06.673244317 +0200
+++ /work/SRC/openSUSE:Factory/.nodejs20.new.1766/nodejs20.changes      
2023-09-10 13:09:58.606011037 +0200
@@ -1,0 +2,7 @@
+Fri Sep  8 10:46:20 UTC 2023 - Adam Majer <adam.ma...@suse.de>
+
+- f0ff63fbc32ea55f3d92c5c89fdb91ec47786859.patch: fixes issues with
+  Angular and other software that tries to load ECM modules in
+  somewhat circular fashion ending up with multiple executions.
+
+-------------------------------------------------------------------

New:
----
  f0ff63fbc32ea55f3d92c5c89fdb91ec47786859.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ nodejs20.spec ++++++
--- /var/tmp/diff_new_pack.5vaAG3/_old  2023-09-10 13:10:01.750123367 +0200
+++ /var/tmp/diff_new_pack.5vaAG3/_new  2023-09-10 13:10:01.754123510 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package nodejs20
 #
-# Copyright (c) 2023 SUSE LLC
+# Copyright (c) 2022 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -15,7 +15,17 @@
 # Please submit bugfixes or comments via https://bugs.opensuse.org/
 #
 
+###########################################################
+#
+#   WARNING! WARNING! WARNING! WARNING! WARNING! WARNING!
+#
+# This spec file is generated from a template hosted at
+# https://github.com/AdamMajer/nodejs-packaging
+#
+###########################################################
 
+# Fedora doesn't have rpm-config-SUSE which provides
+# ext_man in /usr/lib/rpm/macros.d/macros.obs
 %if 0%{?fedora_version}
 %define ext_man .gz
 %endif
@@ -135,6 +145,8 @@
 Patch7:         manual_configure.patch
 Patch13:        openssl_binary_detection.patch
 
+
+
 ## Patches specific to SUSE and openSUSE
 Patch100:       linker_lto_jobs.patch
 # PATCH-FIX-OPENSUSE -- set correct path for dtrace if it is built
@@ -161,9 +173,10 @@
 Patch308:       node-gyp-config.patch
 Patch309:       gcc13.patch
 Patch311:       z13.patch
+Patch312:       f0ff63fbc32ea55f3d92c5c89fdb91ec47786859.patch
 
-BuildRequires:  fdupes
 BuildRequires:  pkg-config
+BuildRequires:  fdupes
 BuildRequires:  procps
 BuildRequires:  xz
 BuildRequires:  zlib-devel
@@ -224,6 +237,7 @@
 BuildRequires:  gcc-c++
 %endif
 
+
 # Python dependencies
 %if %node_version_number >= 14
 
@@ -249,8 +263,8 @@
 %endif
 
 %if 0%{?suse_version} >= 1500 && %{node_version_number} >= 10
-BuildRequires:  group(nobody)
 BuildRequires:  user(nobody)
+BuildRequires:  group(nobody)
 %endif
 
 # shared openssl
@@ -265,10 +279,11 @@
 BuildRequires:  (libopenssl1_1-hmac if libopenssl-1_1-devel)
 BuildRequires:  (libopenssl3-hmac if libopenssl-3-devel)
 %else
-BuildRequires:  libopenssl1_1-hmac
 BuildRequires:  openssl-1_1 >= %{openssl_req_ver}
+BuildRequires:  libopenssl1_1-hmac
 %endif
 
+
 # /suse_version
 %endif
 
@@ -312,7 +327,7 @@
 %if %{with libalternatives}
 Suggests:       alts
 %else
-Requires(postun):%{_sbindir}/update-alternatives
+Requires(postun): %{_sbindir}/update-alternatives
 %endif
 # either for update-alternatives, or their removal
 Requires(post): %{_sbindir}/update-alternatives
@@ -351,8 +366,8 @@
 %endif
 %endif
 
-Provides:       bundled(libuv) = 1.46.0
 Provides:       bundled(uvwasi) = 0.0.18
+Provides:       bundled(libuv) = 1.46.0
 Provides:       bundled(v8) = 11.3.244.8
 %if %{with intree_brotli}
 Provides:       bundled(brotli) = 1.0.9
@@ -360,9 +375,10 @@
 BuildRequires:  pkgconfig(libbrotlidec)
 %endif
 
-Provides:       bundled(base64) = 0.5.0
+
 Provides:       bundled(llhttp) = 8.1.1
 Provides:       bundled(ngtcp2) = 0.8.1
+Provides:       bundled(base64) = 0.5.0
 Provides:       bundled(simdutf) = 3.2.17
 # bundled url-ada parser, not ada
 Provides:       bundled(ada) = 2.6.0
@@ -387,8 +403,8 @@
 Summary:        Development headers for NodeJS 20.x
 Group:          Development/Languages/NodeJS
 Provides:       nodejs-devel = %{version}
-Requires:       %{name} = %{version}
 Requires:       npm20 = %{version}
+Requires:       %{name} = %{version}
 
 %description devel
 This package provides development headers for Node.js needed for creation
@@ -405,12 +421,12 @@
 Requires:       nodejs20 = %{version}
 Provides:       nodejs-npm = %{version}
 Obsoletes:      nodejs-npm < 4.0.0
-Provides:       npm = %{version}
 Provides:       npm(npm) = 9.8.1
+Provides:       npm = %{version}
 %if 0%{?suse_version} >= 1500
 %if %{node_version_number} >= 10
-Requires:       group(nobody)
 Requires:       user(nobody)
+Requires:       group(nobody)
 %endif
 %endif
 Provides:       bundled(node-abbrev) = 1.1.1
@@ -596,9 +612,9 @@
 Provides:       bundled(node-spdx-expression-parse) = 3.0.1
 Provides:       bundled(node-spdx-license-ids) = 3.0.13
 Provides:       bundled(node-ssri) = 10.0.4
+Provides:       bundled(node-string_decoder) = 1.3.0
 Provides:       bundled(node-string-width) = 4.2.3
 Provides:       bundled(node-string-width) = 5.1.2
-Provides:       bundled(node-string_decoder) = 1.3.0
 Provides:       bundled(node-strip-ansi) = 6.0.1
 Provides:       bundled(node-strip-ansi) = 7.1.0
 Provides:       bundled(node-supports-color) = 9.4.0
@@ -707,6 +723,7 @@
 %patch305 -p1
 %patch309 -p1
 %patch311 -p1
+%patch312 -p1
 
 %if %{node_version_number} == 12
 # minimist security update - patch50
@@ -720,6 +737,8 @@
 # abnormalities from patching
 find \( -name \*.js.orig -or -name \*.md.orig -or -name \*.1.orig \) -delete
 
+
+
 %build
 # normalize shebang
 %if %{node_version_number} >= 12
@@ -1079,7 +1098,6 @@
 update-alternatives --remove npx-default %{_bindir}/npx%{node_version_number}
 
 %else
-
 %pre
 # remove files that are no longer owned but provided by update-alternatives
 if ! [ -L %{_mandir}/man1/node.1%{ext_man} ]; then


++++++ f0ff63fbc32ea55f3d92c5c89fdb91ec47786859.patch ++++++
>From f0ff63fbc32ea55f3d92c5c89fdb91ec47786859 Mon Sep 17 00:00:00 2001
From: Antoine du Hamel <duhamelantoine1...@gmail.com>
Date: Tue, 5 Sep 2023 16:19:10 +0200
Subject: [PATCH] esm: fix loading of CJS modules from ESM

---
 lib/internal/modules/esm/translators.js                | 3 ++-
 test/es-module/test-esm-recursive-cjs-dependencies.mjs | 7 +++++++
 test/fixtures/recursive-a.cjs                          | 6 ++++++
 test/fixtures/recursive-b.cjs                          | 3 +++
 4 files changed, 18 insertions(+), 1 deletion(-)
 create mode 100644 test/es-module/test-esm-recursive-cjs-dependencies.mjs
 create mode 100644 test/fixtures/recursive-a.cjs
 create mode 100644 test/fixtures/recursive-b.cjs

diff --git a/lib/internal/modules/esm/translators.js 
b/lib/internal/modules/esm/translators.js
index c0125cd84c37c..80228e895fafc 100644
--- a/lib/internal/modules/esm/translators.js
+++ b/lib/internal/modules/esm/translators.js
@@ -279,7 +279,8 @@ translators.set('commonjs', async function 
commonjsStrategy(url, source,
   // obtained by calling the monkey-patchable CJS loader.
   const cjsLoader = source == null ? (module, source, url, filename) => {
     try {
-      module.load(filename);
+      assert(module === CJSModule._cache[filename]);
+      CJSModule._load(filename);
     } catch (err) {
       enrichCJSError(err, source, url);
       throw err;
diff --git a/test/es-module/test-esm-recursive-cjs-dependencies.mjs 
b/test/es-module/test-esm-recursive-cjs-dependencies.mjs
new file mode 100644
index 0000000000000..d75f0fae95df6
--- /dev/null
+++ b/test/es-module/test-esm-recursive-cjs-dependencies.mjs
@@ -0,0 +1,7 @@
+import '../common/index.mjs';
+import { strictEqual } from 'node:assert';
+
+import '../fixtures/recursive-a.cjs';
+
+strictEqual(global.counter, 1);
+delete global.counter;
diff --git a/test/fixtures/recursive-a.cjs b/test/fixtures/recursive-a.cjs
new file mode 100644
index 0000000000000..a60c0a635ddf6
--- /dev/null
+++ b/test/fixtures/recursive-a.cjs
@@ -0,0 +1,6 @@
+'use strict';
+
+global.counter ??= 0;
+global.counter++;
+
+require('./recursive-b.cjs');
diff --git a/test/fixtures/recursive-b.cjs b/test/fixtures/recursive-b.cjs
new file mode 100644
index 0000000000000..e9f0b5d0701b6
--- /dev/null
+++ b/test/fixtures/recursive-b.cjs
@@ -0,0 +1,3 @@
+'use strict';
+
+require('./recursive-a.cjs');

Reply via email to