How to Fix Error “user admin is not allowed to acc

2020-06-04 12:38发布

I am updated now and running node v5.0.0 npm v3.3.6

On a Mac (El Capitan)

When i run "npm install" on my project now. I get errors like this:

me:controls me$ sudo npm install
npm ERR! Darwin 15.0.0
npm ERR! argv "/usr/local/Cellar/node/0.10.36/bin/node" "/usr/local/bin/npm" "install"
npm ERR! node v5.0.0
npm ERR! npm  v3.3.6
npm ERR! code E403

npm ERR! user admin is not allowed to access package chai : chai
npm ERR! 
npm ERR! If you need help, you may report this error at:
npm ERR!     <https://github.com/npm/npm/issues>

npm ERR! Please include the following file with any support request:
npm ERR!     /Users/me/Dev/controls/npm-debug.log

Im not seeing any solutions to this around the web yet? I tried both sudo and not sudo and makes no difference.

Any suggestions?

标签: npm
1条回答
Deceive 欺骗
2楼-- · 2020-06-04 13:06

I had the same problem. Check the registry: npm config list. Try to run:

npm set registry "https://registry.npmjs.org/"

and then npm i again.

I used sinopia as a registry. Sinopia can't work with scoped packages.

查看更多
登录 后发表回答