bioinformatics-ua/dicoogle

Webapp does not build with Node.js 12

Closed this issue ยท 0 comments

Enet4 commented

See Travis CI build #311.3, for example.

This has mostly likely to do with outdated dependencies.

$ cd dicoogle/src/main/resources/webapp && npm install
npm WARN deprecated babel-preset-es2015@6.24.1: ๐Ÿ™Œ  Thanks for using Babel: we recommend using babel-preset-env now: please read https://babeljs.io/env to update!
npm WARN deprecated gulp-util@3.0.8: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
npm WARN deprecated superagent@3.8.3: Please note that v5.0.1+ of superagent removes User-Agent header by default, therefore you may need to add it yourself (e.g. GitHub blocks requests without a User-Agent header).  This notice will go away with v5.0.2+ once it is released.
npm WARN deprecated graceful-fs@3.0.11: please upgrade to graceful-fs 4 for compatibility with current and future versions of Node.js
npm WARN deprecated core-js@1.2.7: core-js@<2.6.8 is no longer maintained. Please, upgrade to core-js@3 or at least to actual version of core-js@2.
npm WARN deprecated circular-json@0.3.3: CircularJSON is in maintenance only, flatted is its successor.
npm WARN deprecated minimatch@2.0.10: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
npm WARN deprecated natives@1.1.6: This module relies on Node.js's internals and will break at some point. Do not use it, and update to graceful-fs@4.x.
npm WARN deprecated minimatch@0.2.14: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
npm WARN deprecated graceful-fs@1.2.3: please upgrade to graceful-fs 4 for compatibility with current and future versions of Node.js
> node-sass@4.12.0 install /home/travis/build/bioinformatics-ua/dicoogle/dicoogle/src/main/resources/webapp/node_modules/node-sass
> node scripts/install.js
Downloading binary from https://github.com/sass/node-sass/releases/download/v4.12.0/linux-x64-72_binding.node
Download complete
Binary saved to /home/travis/build/bioinformatics-ua/dicoogle/dicoogle/src/main/resources/webapp/node_modules/node-sass/vendor/linux-x64-72/binding.node
Caching binary to /home/travis/.npm/node-sass/4.12.0/linux-x64-72_binding.node
> husky@0.14.3 install /home/travis/build/bioinformatics-ua/dicoogle/dicoogle/src/main/resources/webapp/node_modules/husky
> node ./bin/install.js
husky
CI detected, skipping Git hooks installation
> core-js@2.6.9 postinstall /home/travis/build/bioinformatics-ua/dicoogle/dicoogle/src/main/resources/webapp/node_modules/core-js
> node scripts/postinstall || echo "ignore"
> node-sass@4.12.0 postinstall /home/travis/build/bioinformatics-ua/dicoogle/dicoogle/src/main/resources/webapp/node_modules/node-sass
> node scripts/build.js
Binary found at /home/travis/build/bioinformatics-ua/dicoogle/dicoogle/src/main/resources/webapp/node_modules/node-sass/vendor/linux-x64-72/binding.node
Testing binary
Binary is fine
> dicoogle-webapp@1.3.1 prepare /home/travis/build/bioinformatics-ua/dicoogle/dicoogle/src/main/resources/webapp
> gulp production
fs.js:27
const { Math, Object } = primordials;
                         ^
ReferenceError: primordials is not defined
    at fs.js:27:26
    at req_ (/home/travis/build/bioinformatics-ua/dicoogle/dicoogle/src/main/resources/webapp/node_modules/natives/index.js:143:24)
    at Object.req [as require] (/home/travis/build/bioinformatics-ua/dicoogle/dicoogle/src/main/resources/webapp/node_modules/natives/index.js:55:10)
    at Object.<anonymous> (/home/travis/build/bioinformatics-ua/dicoogle/dicoogle/src/main/resources/webapp/node_modules/vinyl-fs/node_modules/graceful-fs/fs.js:1:37)
    at Module._compile (internal/modules/cjs/loader.js:776:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:787:10)
    at Module.load (internal/modules/cjs/loader.js:643:32)
    at Function.Module._load (internal/modules/cjs/loader.js:556:12)
    at Module.require (internal/modules/cjs/loader.js:683:19)
    at require (internal/modules/cjs/helpers.js:16:16)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! dicoogle-webapp@1.3.1 prepare: `gulp production`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the dicoogle-webapp@1.3.1 prepare script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR!     /home/travis/.npm/_logs/2019-07-10T13_49_55_830Z-debug.log
The command "cd dicoogle/src/main/resources/webapp && npm install" exited with 1.

If it's the same problem as dicoogle-client had, it can be fixed by updating Gulp to v4.