-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Description
System Info
OSX: 10.15.3 Beta
Node.js: 12.14.0
Npm: 6.13.4
Issue
I just started your Angular Essential Training, and was following the steps outlined in the README.md. I came across an issue with getting the project up and running when I cloned your repo locally and tried to install the npm packages. After running npm install I received the following errors:
gypgyp ERR! build error ERR! build error gyp ERR! gypstack Error: 'make' failed with exit code: 2 gypERR! ERR! stack at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23) stack Error: make failed with exit code: 2 gyp gyp ERR! ERR!stack at ChildProcess.emit (events.js:210:5) stackgyp at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23) gypERR! stackERR! at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12) stack at ChildProcess.emit (events.js:210:5) gypgyp ERR!ERR! System Darwin 19.3.0 stack at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12) gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--module=**********/angular-essential-training/node_modules/fsevents/lib/binding/Release/node-v72-darwin-x64/fse.node" "--module_name=fse" "--module_path=**********/angular-essential-training/node_modules/fsevents/lib/binding/Release/node-v72-darwin-x64" "--napi_version=5" "--node_abi_napi=napi" gyp ERR! cwd **********/angular-essential-training/node_modules/fsevents gypgyp ERR!ERR! Systemnode -v Darwin 19.3.0 v12.14.0 gyp gypERR! node-gyp -v v5.0.5 ERR!gyp ERR! not ok command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--module=**********/angular-essential-training/node_modules/fsevents/lib/binding/Release/node-v72-darwin-x64/fse.node" "--module_name=fse" "--module_path=**********/angular-essential-training/node_modules/fsevents/lib/binding/Release/node-v72-darwin-x64" "--napi_version=5" "--node_abi_napi=napi" gyp ERR! cwd **********/angular-essential-training/node_modules/fsevents gyp ERR! node -v v12.14.0 gyp ERR! node-gyp -v v5.0.5 gyp ERR! not ok node-pre-gyp ERR! build error node-pre-gyp ERR! stack Error: Failed to execute '/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --module=**********/angular-essential-training/node_modules/fsevents/lib/binding/Release/node-v72-darwin-x64/fse.node --module_name=fse --module_path=**********/angular-essential-training/node_modules/fsevents/lib/binding/Release/node-v72-darwin-x64 --napi_version=5 --node_abi_napi=napi' (1) node-pre-gyp ERR! stack at ChildProcess.<anonymous> (**********/angular-essential-training/node_modules/fsevents/node_
I was able to resolve the issue by:
- deleting the package-lock.json file
- upgrading node-gyp
npm install -g node-gyp
- then installing the npm packages
npm install
From what I've read, it appears to be an issue with applications built with Node 11 that are rebuilt with Node 12. Hopefully this helps anyone that comes across this issue.