kelektiv / node.bcrypt.js

bcrypt for NodeJs
MIT License
7.44k stars 512 forks source link

npm ERR! bcrypt@5.0.0 install: `node-pre-gyp install --fallback-to-build` #846

Closed eshan1809 closed 3 years ago

eshan1809 commented 3 years ago

npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! bcrypt@5.0.0 install: node-pre-gyp install --fallback-to-build npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the bcrypt@5.0.0 install 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:

recrsn commented 3 years ago

Please provide the complete error message, platform and node version

eshan1809 commented 3 years ago

$ node --version v14.15.3

Error

$ npm install bcrypt

bcrypt@5.0.0 install C:\Users\userName\Documents\Visual Studio Code\Web Dev\Learning\Authentication & Security\Secrets\node_modules\bcrypt node-pre-gyp install --fallback-to-build

'Security\Secrets\node_modules.bin\' is not recognized as an internal or external command, operable program or batch file. internal/modules/cjs/loader.js:883 throw err; ^

Error: Cannot find module 'C:\Users\userName\Documents\Visual Studio Code\Web Dev\Learning\node-pre-gyp\bin\node-pre-gyp' at Function.Module._resolveFilename (internal/modules/cjs/loader.js:880:15) at Function.Module._load (internal/modules/cjs/loader.js:725:27) at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:72:12) at internal/main/run_main_module.js:17:47 { code: 'MODULE_NOT_FOUND', requireStack: [] } npm WARN secrets@1.0.0 No description npm WARN secrets@1.0.0 No repository field.

npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! bcrypt@5.0.0 install: node-pre-gyp install --fallback-to-build npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the bcrypt@5.0.0 install 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! C:\Users\userName\AppData\Roaming\npm-cache_logs\2021-01-06T08_29_23_702Z-debug.log

recrsn commented 3 years ago

Remove that & in Authentication & Security in the path

It is a known npm bug in windows

eshan1809 commented 3 years ago

Thanks, it helped