Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

npm error after running quick start #52

Closed
maya opened this issue Apr 30, 2016 · 4 comments
Closed

npm error after running quick start #52

maya opened this issue Apr 30, 2016 · 4 comments

Comments

@maya
Copy link

maya commented Apr 30, 2016

I got this error after running the quick start npm i @frctl/fractal -g:

Error log: http://cl.ly/g2Ya

25755 verbose stack Error: EACCES: permission denied, open '/Users/mayaben-ari/.npm/_locks/staging-3a08f0df5026584d.lock'
25755 verbose stack     at Error (native)
25756 verbose cwd /Users/mayaben-ari/Code
25757 error Darwin 15.3.0
25758 error argv "/usr/local/Cellar/node/0.12.2_1/bin/node" "/usr/local/bin/npm" "i" "@frctl/fractal" "-g"
25759 error node v6.0.0
25760 error npm  v3.8.6
25761 error path /Users/mayaben-ari/.npm/_locks/staging-3a08f0df5026584d.lock
25762 error code EACCES
25763 error errno -13
25764 error syscall open
25765 error Error: EACCES: permission denied, open '/Users/mayaben-ari/.npm/_locks/staging-3a08f0df5026584d.lock'
25765 error     at Error (native)
25765 error  { Error: EACCES: permission denied, open '/Users/mayaben-ari/.npm/_locks/staging-3a08f0df5026584d.lock'
25765 error     at Error (native)
25765 error   errno: -13,
25765 error   code: 'EACCES',
25765 error   syscall: 'open',
25765 error   path: '/Users/mayaben-ari/.npm/_locks/staging-3a08f0df5026584d.lock' }
25766 error Please try running this command again as root/Administrator.
25767 verbose exit [ -13, true ]

Background: I had an older version of node.js when I ran it first, got an error, then updated to the latest stable version.

@allmarkedup
Copy link
Member

@maya that is not a Fractal error but a problem with the permissions on your NPM installation - these docs on fixing permissions errors should help fix the issue. You can also try running the Fractal global install using sudo - i.e. sudo npm i @frctl/fractal -g but I'd advise against that as you may run into more permissions issues later on down the line.

@maya
Copy link
Author

maya commented May 3, 2016

I think I updated my permissions, and now get this....

➜  Code npm i -g @frctl/fractal
npm ERR! registry error parsing json
/usr/local/bin/fractal -> /usr/local/lib/node_modules/@frctl/fractal/bin/fractal

> fsevents@1.0.12 install /usr/local/lib/node_modules/@frctl/fractal/node_modules/fsevents
> node-pre-gyp install --fallback-to-build

gyp ERR! configure error
gyp ERR! stack Error: Python executable "/Users/mayaben-ari/.pyenv/shims/python" is v3.4.1, which is not supported by gyp.
gyp ERR! stack You can pass the --python switch to point to Python >= v2.5.0 & < 3.0.0.
gyp ERR! stack     at failPythonVersion (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:406:14)
gyp ERR! stack     at /usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:395:9
gyp ERR! stack     at ChildProcess.exithandler (child_process.js:193:7)
gyp ERR! stack     at emitTwo (events.js:106:13)
gyp ERR! stack     at ChildProcess.emit (events.js:191:7)
gyp ERR! stack     at maybeClose (internal/child_process.js:850:16)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:215:5)
gyp ERR! System Darwin 15.3.0
gyp ERR! command "/usr/local/Cellar/node/6.0.0/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "configure" "--fallback-to-build" "--module=/usr/local/lib/node_modules/@frctl/fractal/node_modules/fsevents/lib/binding/Release/node-v48-darwin-x64/fse.node" "--module_name=fse" "--module_path=/usr/local/lib/node_modules/@frctl/fractal/node_modules/fsevents/lib/binding/Release/node-v48-darwin-x64"
gyp ERR! cwd /usr/local/lib/node_modules/@frctl/fractal/node_modules/fsevents
gyp ERR! node -v v6.0.0
gyp ERR! node-gyp -v v3.3.1
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute '/usr/local/Cellar/node/6.0.0/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/usr/local/lib/node_modules/@frctl/fractal/node_modules/fsevents/lib/binding/Release/node-v48-darwin-x64/fse.node --module_name=fse --module_path=/usr/local/lib/node_modules/@frctl/fractal/node_modules/fsevents/lib/binding/Release/node-v48-darwin-x64' (1)
node-pre-gyp ERR! stack     at ChildProcess.<anonymous> (/usr/local/lib/node_modules/@frctl/fractal/node_modules/fsevents/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
node-pre-gyp ERR! stack     at emitTwo (events.js:106:13)
node-pre-gyp ERR! stack     at ChildProcess.emit (events.js:191:7)
node-pre-gyp ERR! stack     at maybeClose (internal/child_process.js:850:16)
node-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:215:5)
node-pre-gyp ERR! System Darwin 15.3.0
node-pre-gyp ERR! command "/usr/local/Cellar/node/6.0.0/bin/node" "/usr/local/lib/node_modules/@frctl/fractal/node_modules/fsevents/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build"
node-pre-gyp ERR! cwd /usr/local/lib/node_modules/@frctl/fractal/node_modules/fsevents
node-pre-gyp ERR! node -v v6.0.0
node-pre-gyp ERR! node-pre-gyp -v v0.6.25
node-pre-gyp ERR! not ok
Failed to execute '/usr/local/Cellar/node/6.0.0/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/usr/local/lib/node_modules/@frctl/fractal/node_modules/fsevents/lib/binding/Release/node-v48-darwin-x64/fse.node --module_name=fse --module_path=/usr/local/lib/node_modules/@frctl/fractal/node_modules/fsevents/lib/binding/Release/node-v48-darwin-x64' (1)
npm WARN install:fsevents@1.0.12 fsevents@1.0.12 install: `node-pre-gyp install --fallback-to-build`
npm WARN install:fsevents@1.0.12 Exit status 1
/usr/local/lib
└─┬ @frctl/fractal@0.11.0
  ├── @allmarkedup/dirscribe@1.0.0
  ├── @allmarkedup/fang@1.0.0
  ├─┬ @frctl/handlebars-adapter@0.4.9
  │ ├─┬ @frctl/handlebars-helpers@0.3.0
  ...

@maya
Copy link
Author

maya commented May 3, 2016

Btw we'd love to chat with you about fractal in the design systems slack: http://designsystems.herokuapp.com/

@allmarkedup
Copy link
Member

Hi @maya - I've had a look into this and it seems that node-gyp (that is used by many upstream dependencies) doesn't work with Python 3: nodejs/node-gyp#193 - it sounds like it's this that is causing you an issue.

You can try and solve the issue by installing node-gyp as a global module, pointing it to an older version of python (if you still have one on your machine), using something like node-gyp --python /path/to/python2.7and then trying to re-run npm i -g @frctl/fractal. Lots of yak-shaving I'm afraid!

And thanks for the Design Systems slack link - @adactio mentioned it the other day actually too and I've been meaning to check it out. I'm slightly drowning in Slack messages at the moment but it sounds good so I'll jump in :-)

mihkeleidast pushed a commit that referenced this issue May 21, 2020
Add user-configurable `beautify` filter
mihkeleidast pushed a commit that referenced this issue May 21, 2020
Add user-configurable `beautify` filter
mihkeleidast pushed a commit that referenced this issue May 23, 2020
Add user-configurable `beautify` filter
mihkeleidast pushed a commit that referenced this issue May 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants