Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Bug#1004540: node-graphql build failure with current babel (passed with an older babel)

24 views
Skip to first unread message

Pirate Praveen

unread,
Jan 30, 2022, 4:30:03 AM1/30/22
to
Package: node-babel7
Version: 7.16.10+~cs214.260.188-1

(debian-sid)pravi@mahishi:~/forge/js-team/node-graphql$
dpkg-buildpackage
dpkg-buildpackage: info: source package node-graphql
dpkg-buildpackage: info: source version 15.5.0-1
dpkg-buildpackage: info: source distribution UNRELEASED
dpkg-buildpackage: info: source changed by Pirate Praveen
<pra...@debian.org>
dpkg-buildpackage: info: host architecture amd64
dpkg-source --before-build .
debian/rules clean
dh clean
dh_auto_clean --buildsystem=nodejs
rm -rf ./node_modules/.cache
dh_clean
dpkg-source -b .
dpkg-source: info: using source format '3.0 (quilt)'
dpkg-source: info: building node-graphql using existing
./node-graphql_15.5.0.orig.tar.gz
dpkg-source: info: building node-graphql in
node-graphql_15.5.0-1.debian.tar.xz
dpkg-source: info: building node-graphql in node-graphql_15.5.0-1.dsc
debian/rules binary
dh binary
dh_update_autotools_config
dh_autoreconf
dh_auto_configure --buildsystem=nodejs
dh_auto_build --buildsystem=nodejs
Found debian/nodejs/./build
cd ./. && sh -ex debian/nodejs/./build
+ node resources/build-npm.js
/usr/share/nodejs/@babel/core/lib/config/files/plugins.js:139
throw error;
^

Error: Cannot find module './resources/add-extension-to-import-paths'
Require stack:
- /usr/share/nodejs/@babel/core/lib/config/files/plugins.js
- /usr/share/nodejs/@babel/core/lib/config/files/index.js
- /usr/share/nodejs/@babel/core/lib/index.js
- /home/pravi/forge/js-team/node-graphql/resources/build-npm.js
- Did you accidentally pass a preset as a plugin?
at Function.Module._resolveFilename
(internal/modules/cjs/loader.js:815:15)
at resolve (internal/modules/cjs/helpers.js:80:19)
at tryRequireResolve
(/usr/share/nodejs/@babel/core/lib/config/files/plugins.js:157:9)
at resolveStandardizedNameForRequrie
(/usr/share/nodejs/@babel/core/lib/config/files/plugins.js:195:17)
at sync
(/usr/share/nodejs/@babel/core/lib/config/files/plugins.js:229:12)
at sync (/usr/share/nodejs/gensync/index.js:182:19)
at /usr/share/nodejs/gensync/index.js:210:24
at Generator.next (<anonymous>)
at resolvePlugin
(/usr/share/nodejs/@babel/core/lib/config/files/plugins.js:83:17)
at resolvePlugin.next (<anonymous>) {
code: 'MODULE_NOT_FOUND',
requireStack: [
'/usr/share/nodejs/@babel/core/lib/config/files/plugins.js',
'/usr/share/nodejs/@babel/core/lib/config/files/index.js',
'/usr/share/nodejs/@babel/core/lib/index.js',
'/home/pravi/forge/js-team/node-graphql/resources/build-npm.js'
]
}
dh_auto_build: error: cd ./. && sh -ex debian/nodejs/./build returned
exit code 1
make: *** [debian/rules:8: binary] Error 1

This same failure is repeated when running sbuild too. node-graphql is
is salsa.

But in a chroot where I had an old version of babel the build passed,

$ apt policy node-babel7
node-babel7:
Installed: 7.12.12+~cs150.141.84-8
Candidate: 7.16.10+~cs214.260.188-1
Version table:
7.16.10+~cs214.260.188-1 500
500 http://deb.debian.org/debian sid/main amd64 Packages
*** 7.12.12+~cs150.141.84-8 100
100 /var/lib/dpkg/status

$ dpkg-buildpackage
dpkg-buildpackage: info: source package node-graphql
dpkg-buildpackage: info: source version 15.5.0-1
dpkg-buildpackage: info: source distribution UNRELEASED
dpkg-buildpackage: info: source changed by Pirate Praveen
<pra...@debian.org>
dpkg-buildpackage: info: host architecture amd64
dpkg-source --before-build .
debian/rules clean
dh clean
dh_auto_clean --buildsystem=nodejs
rm -rf ./node_modules/.cache
dh_clean
dpkg-source -b .
dpkg-source: info: using source format '3.0 (quilt)'
dpkg-source: info: building node-graphql using existing
./node-graphql_15.5.0.orig.tar.gz
dpkg-source: info: building node-graphql in
node-graphql_15.5.0-1.debian.tar.xz
dpkg-source: info: building node-graphql in node-graphql_15.5.0-1.dsc
debian/rules binary
dh binary
dh_update_autotools_config
dh_autoreconf
dh_auto_configure --buildsystem=nodejs
dh_auto_build --buildsystem=nodejs
Found debian/nodejs/./build
cd ./. && sh -ex debian/nodejs/./build
+ node resources/build-npm.js
*.js x140 | 660.75 KB
*.js.flow x140 | 624.32 KB
*.mjs x140 | 573.01 KB
*.d.ts x112 | 188.03 KB
README.md | 5.90 KB
LICENSE | 1.05 KB
package.json | 0.55 KB
--------------------------
Total | 2.01 MB
dh_auto_test --buildsystem=nodejs
mkdir -p node_modules
ln -s ../. node_modules/graphql
/usr/bin/node -e require\(\"./.\"\)
internal/modules/cjs/loader.js:303
throw err;
^

Error: Cannot find module
'/home/pravi/forge/js-team/node-graphql/index'. Please verify that the
package.json has a valid "main" entry
at tryPackage (internal/modules/cjs/loader.js:295:19)
at Function.Module._findPath (internal/modules/cjs/loader.js:508:18)
at Function.Module._resolveFilename
(internal/modules/cjs/loader.js:802:27)
at Function.Module._load (internal/modules/cjs/loader.js:667:27)
at Module.require (internal/modules/cjs/loader.js:887:19)
at require (internal/modules/cjs/helpers.js:74:18)
at [eval]:1:1
at Script.runInThisContext (vm.js:120:18)
at Object.runInThisContext (vm.js:309:38)
at Object.<anonymous> ([eval]-wrapper:10:26) {
code: 'MODULE_NOT_FOUND',
path: '/home/pravi/forge/js-team/node-graphql/package.json',
requestPath: './.'
}
dh_auto_test: error: /usr/bin/node -e require\(\"./.\"\) returned exit
code 1
make: *** [debian/rules:8: binary] Error 255

Note: Require is failing because the build creates npmDist directory.

Pirate Praveen

unread,
Feb 1, 2022, 7:20:03 AM2/1/22
to
Control: severity -1 grave

On ഞാ, ജനു 30 2022 at 02:48:39 വൈകു +0530 +0530,
Pirate Praveen <pra...@onenetbeyond.org> wrote:
>
> Error: Cannot find module './resources/add-extension-to-import-paths'
>

This is caused by this patch to load modules from system,
https://salsa.debian.org/js-team/node-babel/-/blob/master/debian/patches/load-plugins-from-system-libraries.diff

This breaks plugins specified as relative paths.

Yadd

unread,
Feb 1, 2022, 8:10:04 AM2/1/22
to
Hi,

fixed in 7.16.12+~cs214.260.189-2, I fixed also your package
(auto_install + test)

Cheers,
Yadd

Pirate Praveen

unread,
Feb 1, 2022, 8:10:05 AM2/1/22
to


On ചൊ, ഫെബ്രു 1 2022 at 02:01:22 വൈകു +0100
+0100, Yadd <ya...@debian.org> wrote:
>>
> Note: package isn't totally broken as it is able to rebuild itself,
> so changing severity to important from grave (only partially broken)

I think not finding plugins from local paths is grave for a package
like babel which has lots of plugins (the goal of a package like babel
is not to build itself but build other packages). But since it is fixed
anyway, I don't mind the lowering of severity.

Jonas Smedegaard

unread,
Feb 1, 2022, 9:30:04 AM2/1/22
to
Quoting Pirate Praveen (2022-02-01 14:06:59)
I'd say "grave" is too severe. Choice of either "serious" or
"important" depends not on amount of plugins but whether any packages
already in testing would fail to work (e.g. fail to build from source)
if the package were to transition to testing.

In other words, if raising severity then mention some concrete packages
affected, and if lowering severity then mention concretely how the issue
does *not* affect existing dependencies.


- Jonas

--
* Jonas Smedegaard - idealist & Internet-arkitekt
* Tlf.: +45 40843136 Website: http://dr.jones.dk/

[x] quote me freely [ ] ask before reusing [ ] keep private
signature.asc
0 new messages