0
votes

While update npm with latest version getting some error and warring

c:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External>npm cache clean --force npm WARN using --force I sure hope you know what you are doing.

c:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External>npm install npm@latest -g

npm http GET https://registry.npmjs.org/npm

npm http 200 https://registry.npmjs.org/npm

npm http GET https://registry.npmjs.org/npm/-/npm-6.5.0.tgz

npm http 200 https://registry.npmjs.org/npm/-/npm-6.5.0.tgz

npm WARN package.json [email protected] No README data

npm WARN package.json [email protected] No README data

npm WARN package.json [email protected] punycode is also the name of a node core module.

npm WARN package.json [email protected] string_decoder is also the name of a node core module.

c:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External\node\npx -> c:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External\node\node_modules\npm\bin\npx-cli.js

c:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External\node\npm -> c:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External\node\node_modules\npm\bin\npm-cli.js

[email protected] c:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External\node\node_modules\npm

Help me for update this mnp version. Due this i'm unable to restore package.json getting Error

npm ERR! Error: Method Not Allowed

npm ERR! at errorResponse (C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External\npm\node_modules\npm\lib\cache.js:753:14) npm ERR! at C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External\npm\node_modules\npm\lib\cache.js:773:12

npm ERR! at saved (C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External\npm\node_modules\npm-registry-client\lib\get.js:148:7)

npm ERR! at C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External\npm\node_modules\graceful-fs\polyfills.js:133:7

npm ERR! at Object.oncomplete (fs.js:107:15)

npm ERR! If you need help, you may report this entire log,

npm ERR! including the npm and node versions, at:

npm ERR! http://github.com/npm/npm/issues

npm ERR! System Windows_NT 6.2.9200

npm ERR! command "C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External\node\node" "C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External\npm\node_modules\npm\bin\npm-cli.js" "install"

npm ERR! cwd C:\Users\VIKAS\documents\visual studio

2015\Projects\Angular2\Angular2

npm ERR! node -v v0.10.31

npm ERR! npm -v 1.4.9

npm ERR! code E405

1
Have you try npm cache clean || npm cache clean --force?Abhishek
Yes but not able to fix the issue?Syan
try this npm uninstall -g angular-cli npm cache clean or npm cache verify (if npm > 5) npm install -g @angular/cli@latestAbhishek
Still getting errorSyan
if i'm not wrong currently you are using angular 2 and try to update with latest? link go through with this doc i think it is helpful for you.Abhishek

1 Answers

2
votes

You can upgrade to the latest version of npm using:

npm install -g npm@latest

Or upgrade to the most recent release:

npm install -g npm@next

For More Details Click Here