Juice-shop: fail to run juice shop

Created on 15 Dec 2019  ·  7Comments  ·  Source: bkimminich/juice-shop

root@kali:~/Desktop/juice-shop1# npm start

[email protected] start /root/Desktop/juice-shop1
node app

info: All dependencies in ./package.json are satisfied (OK)
(node:49520) UnhandledPromiseRejectionWarning: Error: The module '/root/Desktop/juice-shop1/node_modules/libxmljs2/build/Release/xmljs.node'
was compiled against a different Node.js version using
NODE_MODULE_VERSION 64. This version of Node.js requires
NODE_MODULE_VERSION 72. Please try re-compiling or re-installing
the module (for instance, using `npm rebuild` or `npm install`).
    at Object.Module._extensions..node (internal/modules/cjs/loader.js:1025:18)
    at Module.load (internal/modules/cjs/loader.js:815:32)
    at Function.Module._load (internal/modules/cjs/loader.js:727:14)
    at Module.require (internal/modules/cjs/loader.js:852:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at bindings (/root/Desktop/juice-shop1/node_modules/bindings/bindings.js:112:48)
    at Object.<anonymous> (/root/Desktop/juice-shop1/node_modules/libxmljs2/lib/bindings.js:1:37)
    at Module._compile (internal/modules/cjs/loader.js:959:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:995:10)
    at Module.load (internal/modules/cjs/loader.js:815:32)
    at Function.Module._load (internal/modules/cjs/loader.js:727:14)
    at Module.require (internal/modules/cjs/loader.js:852:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/root/Desktop/juice-shop1/node_modules/libxmljs2/index.js:4:16)
    at Module._compile (internal/modules/cjs/loader.js:959:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:995:10)
(node:49520) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:49520) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

What should I do now ?? Thanks

All 7 comments

Thanks a lot for opening your first issue with us! 🧡 We'll get back to you shortly! ⏳ If it was a _Support Request_, please consider asking on the community chat next time! 💬

Hi 👋
According to the error you installed Juice Shop initially using a different Node.js version.
You probably need to reinstall Juice Shop for the current node version.

Try to the delete the node_modules folder to remove the old version of the dependencies and then run npm install.

Looks more like you downloaded the wrong ZIP. Download the version for your node.js (10, 12 or 13) and it should work. Also make sure to pick the archive for the righr OS. Or: Clone the repo instead and do.npm install.

For future support requests please use Gitter preferably, thanks!

Yes and my Nodejs is 12 , Juice shop version is 9.3.0 , this is exactly what this version of Juice Shop required

after I installed Node js 13 , I still got this error :
root@kali:~/Desktop/juice-shop# npm start

[email protected] start /root/Desktop/juice-shop
node app

info: All dependencies in ./package.json are satisfied (OK)
(node:5035) UnhandledPromiseRejectionWarning: Error: The module '/root/Desktop/juice-shop/node_modules/libxmljs2/build/Release/xmljs.node'
was compiled against a different Node.js version using
NODE_MODULE_VERSION 72. This version of Node.js requires
NODE_MODULE_VERSION 79. Please try re-compiling or re-installing
the module (for instance, using npm rebuild or npm install).

Ah okay , I got it , thanks

Was this page helpful?
0 / 5 - 0 ratings