Error installing Contextify on OSX (Failed at the [email protected] install script 'node-gyp rebuild')
Here is a little more info for the above error:
gyp ERR! UNCAUGHT EXCEPTION
gyp ERR! stack Error: spawn EACCES
gyp ERR! stack at exports._errnoException (util.js:1012:11)
gyp ERR! stack at ChildProcess.spawn (internal/child_process.js:302:11)
gyp ERR! stack at exports.spawn (child_process.js:372:9)
gyp ERR! stack at exports.execFile (child_process.js:139:15)
gyp ERR! stack at checkPythonVersion (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:371:5)
gyp ERR! stack at /usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:338:9
gyp ERR! stack at /usr/local/lib/node_modules/npm/node_modules/which/which.js:88:20
gyp ERR! stack at /usr/local/lib/node_modules/npm/node_modules/which/node_modules/isexe/index.js:44:5
gyp ERR! stack at /usr/local/lib/node_modules/npm/node_modules/which/node_modules/isexe/access.js:8:5
gyp ERR! stack at FSReqWrap.oncomplete (fs.js:123:15)
gyp ERR! System Darwin 15.6.0
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/dan/work/Phase2/voyce/repo/node_modules/contextify
gyp ERR! node -v v6.3.1
gyp ERR! node-gyp -v v3.3.1
gyp ERR! This is a bug in `node-gyp`.
gyp ERR! Try to update node-gyp and file an Issue if it does not help:
gyp ERR! <https://github.com/nodejs/node-gyp/issues>
[email protected] /Users/dan/work/Phase2/voyce/repo
└── (empty)
npm ERR! Darwin 15.6.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install"
npm ERR! node v6.3.1
npm ERR! npm v3.10.3
npm ERR! code ELIFECYCLE
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 7
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the contextify package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs contextify
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls contextify
npm ERR! There is likely additional logging output above.
Found this error when running npm install
Ubuntu 16.04, Node v7.0.0
Node 6.9.1 is OK!
I have problem when run node-gyp rebuild.
Mac OS X 10.12.1, Node v7.0.0
../src/contextify.cc:150:16: error: no member named 'SetAccessCheckCallbacks' in 'v8::ObjectTemplate'
otmpl->SetAccessCheckCallbacks(GlobalPropertyNamedAccessCheck,
~~~~~ ^
Issue resolved with node -v v6.9.1
npm -v 3.10.8
@brianmcd Are aware you of any fix for this except for downgrading node version.
I am currently trying to work with node v7.1.0, npm v4.0.2 on macOS Sierra 10.12.1.
I know maintaining open source project is tough and I appreciate your efforts.
Hi. same pbl on El Capitan,
$ npm -v ; node -v
4.1.1
v7.4.0
Same problem here, though it persists after downgrading node. Any other workarounds?
$ npm -v ; node -v
3.10.8
v6.9.1
Temporarily downgrading Node via nvm works until you upgrade it again. Then node tells you to rebuild it, because it was compiled with a different version of Node.
@HsuTing Node 7 must have removed that because on node 6.9.0 I get a deprecated warning instead.
Works for me with
$ npm -v ; node -v
3.10.10
v6.9.5
Seems like it doesn't support node 7 indeed.
@nderkach Rather the other way around; node 7 doesn't support contextify.
Instead, it seems to have been implemented as a native vm module. But npm modules still require this version, for some reason.
I had the same problem and here is how I solved:
$ rm -rf node_modules
$ sudo npm install
$ npm start
For some cryptic reason, node-gyp requires something that's related to my sudo user. I'm investigating yet, but I'm sharing this here because this information could be useful for someone else.
Before that I did:
- How I'm using
nvmto manage NodeJS versions (Currently I'm using versions 4.3.2, 5.7.0 and 6.7.0) I removed and installed again; - How I notice that
node-gypuses tools like make, I updated my computer usingbrew update;
@willmendesneto The issue is 7.0.0 and higher. Solutions for 6.7.0 are invalid.
I was finally able to resolve this issue by adding node-gyp to my devDependencies:
yarn add -D node-gyp
or
npm install -D node-gyp
npm -v ; node -v
4.1.2
v7.6.0
Still having this issue. Any solution besides adding it as a devDependency ? Seems too much of an overkill 🤔
npm -v ; sudo node -v
4.4.4
v7.0.0
Same issue here
Same issue here
npm v4.8.0 node v7.8.0
Same here...
node v7.9.0 npm v4.2.0
Same here: node: v 7.10.0 npm: 4.5.0
idem: node: v7.9.0 npm: 4.5.0