#1078902 science.js: FTBFS: Error parsing /<<PKGBUILDDIR>>/package.json: Unexpected end of JSON input

Package:
src:science.js
Source:
src:science.js
Submitter:
Santiago Vila
Date:
2026-05-23 10:21:06 UTC
Severity:
normal
Tags:
#1078902#5
Date:
2024-08-17 13:41:16 UTC
From:
To:
Dear maintainer:

During a rebuild of all packages in bookworm, your package failed to build:
--------------------------------------------------------------------------------
[...]
  debian/rules binary
dh binary
    dh_update_autotools_config
    dh_autoreconf
    dh_auto_configure --buildsystem=nodejs
/!\ ./package.json not found
    debian/rules override_dh_auto_build
make[1]: Entering directory '/<<PKGBUILDDIR>>'
make JS_COMPILER=uglifyjs
make[2]: Entering directory '/<<PKGBUILDDIR>>'
cat src/core/core.js src/core/ascending.js src/core/constants.js src/core/expm1.js src/core/functor.js src/core/hypot.js src/core/quadratic.js src/core/zeroes.js >> science.core.js
cat src/lin/lin.js src/lin/decompose.js src/lin/cross.js src/lin/dot.js src/lin/length.js src/lin/normalize.js src/lin/determinant.js src/lin/gaussjordan.js src/lin/inverse.js src/lin/multiply.js src/lin/transpose.js src/lin/tridag.js >> science.lin.js
cat src/stats/stats.js src/stats/bandwidth.js src/stats/distance.js src/stats/erf.js src/stats/phi.js src/stats/kernel.js src/stats/kde.js src/stats/kmeans.js src/stats/hcluster.js src/stats/iqr.js src/stats/loess.js src/stats/mean.js src/stats/median.js src/stats/mode.js src/stats/quantiles.js src/stats/variance.js src/stats/distribution.js src/stats/distribution/gaussian.js >> science.stats.js
cat science.core.js science.lin.js science.stats.js >> science.v1.js
uglifyjs < science.v1.js > science.v1.min.js
node src/package.js > package.json
node:internal/modules/package_json_reader:92
         throw error;
         ^

SyntaxError: Error parsing /<<PKGBUILDDIR>>/package.json: Unexpected end of JSON input
     at parse (<anonymous>)
     at read (node:internal/modules/package_json_reader:79:16)
     at readPackage (node:internal/modules/package_json_reader:140:10)
     at readPackageScope (node:internal/modules/package_json_reader:157:19)
     at shouldUseESMLoader (node:internal/modules/run_main:77:15)
     at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:122:24)
     at node:internal/main/run_main_module:28:49 {
   path: '/<<PKGBUILDDIR>>/package.json'
}

Node.js v18.19.0
make[2]: *** [Makefile:80: package.json] Error 1
rm science.lin.js science.stats.js science.core.js
make[2]: Leaving directory '/<<PKGBUILDDIR>>'
make[1]: *** [debian/rules:11: override_dh_auto_build] Error 2
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
make: *** [debian/rules:8: binary] Error 2
dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2
--------------------------------------------------------------------------------

The above is just how the build ends and not necessarily the most relevant part.
If required, the full build log is available here:

https://people.debian.org/~sanvila/build-logs/bookworm/

About the archive rebuild: The build was made on virtual machines
of type m6a.large and r6a.large from AWS, using sbuild and a
reduced chroot with only build-essential packages.

If you could not reproduce the bug please contact me privately, as I
am willing to provide ssh access to a virtual machine where the bug is
fully reproducible.

If this is really a bug in one of the build-depends, please use
reassign and affects, so that this is still visible in the BTS web
page for this package.

Thanks.

#1078902#20
Date:
2026-05-23 10:18:49 UTC
From:
To:
We believe that the bug you reported is fixed in the latest version of
science.js, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 1058552@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Santiago Vila <sanvila@debian.org> (supplier of updated science.js package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)
Format: 1.8
Date: Wed, 20 May 2026 00:30:00 +0200
Source: science.js
Architecture: source
Version: 1.9.3+dfsg-3+deb12u1
Distribution: bookworm
Urgency: medium
Maintainer: Debian Javascript Maintainers <pkg-javascript-devel@lists.alioth.debian.org>
Changed-By: Santiago Vila <sanvila@debian.org>
Closes: 1058552 1078902
Changes:
 science.js (1.9.3+dfsg-3+deb12u1) bookworm; urgency=medium
 .
   * Team upload.
 .
   [ Petter Reinholdtsen ]
   * Fixed build race condition problem. Closes: #1058552, #1078902.
Checksums-Sha1:
 cb57170d069c5ec5a01e2d73a5846665c5fc1f86 1833 science.js_1.9.3+dfsg-3+deb12u1.dsc
 85f16e2d61c36847397c22aa6a9ca15808798df6 5236 science.js_1.9.3+dfsg-3+deb12u1.debian.tar.xz
 56261943e75dbbb51d8c96bf48ce7bba9fd32839 8123 science.js_1.9.3+dfsg-3+deb12u1_source.buildinfo
Checksums-Sha256:
 7a675fa46ce2d8d240391380905d31f9fd9d041548797f1f64bd364f752bc965 1833 science.js_1.9.3+dfsg-3+deb12u1.dsc
 8a91005fcd86166b9d30f658340f66698e385af7f6c9d082530b0f535204d46f 5236 science.js_1.9.3+dfsg-3+deb12u1.debian.tar.xz
 ae4c978edcda93f14df2486d2f9de1afd9d188241fd49498098ced49da1cb847 8123 science.js_1.9.3+dfsg-3+deb12u1_source.buildinfo
Files:
 227f179823e100ce05cc20a9d5d5375f 1833 javascript optional science.js_1.9.3+dfsg-3+deb12u1.dsc
 82df8757fae39b47de1077022c058e75 5236 javascript optional science.js_1.9.3+dfsg-3+deb12u1.debian.tar.xz
 bd3da2b1300ed133d953136426787891 8123 javascript optional science.js_1.9.3+dfsg-3+deb12u1_source.buildinfo
-----BEGIN PGP SIGNATURE-----

iQEzBAEBCgAdFiEE1Uw7+v+wQt44LaXXQc5/C58bizIFAmoM7uYACgkQQc5/C58b
izJ5fgf/fNpyl8oUD8HiyExa4uL4sCC8jCwsqD4QC1EMRX5wHWlmuTQOWM3VUyYa
sRkLepCV+3NsreoKpP+fs6ISyqGQhVKtp4hksqu13X0rUlGXe8R0cROvHsxzdIsb
vbskP5UfDoRxykScXGtiHG3e8XJv/4/tAoSykUBAdLvX1jHuZ2gsZ1pcXizi3JQC
6YV1etwy6DZDVje1xI/yqsxhYjp95JD2bL34zryWAoSfNKenQSP1MStS2aotlpAJ
NWQnBCBSuHFo4kb5ny5x0bqMYmOZ9AG/SmweT/bTosM/Lc74VtLxZcGN96+kP+40
u5ywT1U7XyVYAl/KfIfQgnhKRI/tFA==
=mVKP
-----END PGP SIGNATURE-----

#1078902#25
Date:
2026-05-23 10:18:49 UTC
From:
To:
We believe that the bug you reported is fixed in the latest version of
science.js, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 1078902@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Santiago Vila <sanvila@debian.org> (supplier of updated science.js package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)
Format: 1.8
Date: Wed, 20 May 2026 00:30:00 +0200
Source: science.js
Architecture: source
Version: 1.9.3+dfsg-3+deb12u1
Distribution: bookworm
Urgency: medium
Maintainer: Debian Javascript Maintainers <pkg-javascript-devel@lists.alioth.debian.org>
Changed-By: Santiago Vila <sanvila@debian.org>
Closes: 1058552 1078902
Changes:
 science.js (1.9.3+dfsg-3+deb12u1) bookworm; urgency=medium
 .
   * Team upload.
 .
   [ Petter Reinholdtsen ]
   * Fixed build race condition problem. Closes: #1058552, #1078902.
Checksums-Sha1:
 cb57170d069c5ec5a01e2d73a5846665c5fc1f86 1833 science.js_1.9.3+dfsg-3+deb12u1.dsc
 85f16e2d61c36847397c22aa6a9ca15808798df6 5236 science.js_1.9.3+dfsg-3+deb12u1.debian.tar.xz
 56261943e75dbbb51d8c96bf48ce7bba9fd32839 8123 science.js_1.9.3+dfsg-3+deb12u1_source.buildinfo
Checksums-Sha256:
 7a675fa46ce2d8d240391380905d31f9fd9d041548797f1f64bd364f752bc965 1833 science.js_1.9.3+dfsg-3+deb12u1.dsc
 8a91005fcd86166b9d30f658340f66698e385af7f6c9d082530b0f535204d46f 5236 science.js_1.9.3+dfsg-3+deb12u1.debian.tar.xz
 ae4c978edcda93f14df2486d2f9de1afd9d188241fd49498098ced49da1cb847 8123 science.js_1.9.3+dfsg-3+deb12u1_source.buildinfo
Files:
 227f179823e100ce05cc20a9d5d5375f 1833 javascript optional science.js_1.9.3+dfsg-3+deb12u1.dsc
 82df8757fae39b47de1077022c058e75 5236 javascript optional science.js_1.9.3+dfsg-3+deb12u1.debian.tar.xz
 bd3da2b1300ed133d953136426787891 8123 javascript optional science.js_1.9.3+dfsg-3+deb12u1_source.buildinfo
-----BEGIN PGP SIGNATURE-----

iQEzBAEBCgAdFiEE1Uw7+v+wQt44LaXXQc5/C58bizIFAmoM7uYACgkQQc5/C58b
izJ5fgf/fNpyl8oUD8HiyExa4uL4sCC8jCwsqD4QC1EMRX5wHWlmuTQOWM3VUyYa
sRkLepCV+3NsreoKpP+fs6ISyqGQhVKtp4hksqu13X0rUlGXe8R0cROvHsxzdIsb
vbskP5UfDoRxykScXGtiHG3e8XJv/4/tAoSykUBAdLvX1jHuZ2gsZ1pcXizi3JQC
6YV1etwy6DZDVje1xI/yqsxhYjp95JD2bL34zryWAoSfNKenQSP1MStS2aotlpAJ
NWQnBCBSuHFo4kb5ny5x0bqMYmOZ9AG/SmweT/bTosM/Lc74VtLxZcGN96+kP+40
u5ywT1U7XyVYAl/KfIfQgnhKRI/tFA==
=mVKP
-----END PGP SIGNATURE-----