errorwheninstallingnpm

(Doug) #1

Unhandled rejection Error: EACCES: permission denied, open ‘/Users/dougclayton/.npm/_cacache/tmp/a6b2e996’

0 Likes

(John Gee) #2

Assuming you were trying an install…

There is an open issue with installing global packages using sudo leaving behind files with the wrong ownership.

The short version is run this to fix the ownership, then try your install again:


sudo chown -R $(whoami) ~/.npm

The long version and canonical bug is: Global installs (sudo npm i -g) fail on Mac after 6.5 upgrade. Works fine after 6.4.1 downgrade.

0 Likes

(Doug) #3

Thank you very much! I’m trying it now.

0 Likes

(Doug) #4

This did not work. Any other things I can try?

0 Likes

(John Gee) #5

That was my best guess, but we haven’t got much to work with. :slight_smile:

What command are you running? (i.e. the full command line you are running)

What version of npm and node, and platform are you on?

$ npm --versions
<!-- paste output here -->
$ node -p process.platform
<!-- paste output here -->
0 Likes