-
Notifications
You must be signed in to change notification settings - Fork 154
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
Unable to update npm using npm i -g npm
#224
Comments
Have you tried installing node and npm via the official installation method? The error still persists in that case? |
Also, can you run the command |
Sorry for the delay.
|
I was able to install node using apt package manager with no issues.
I don't really understand how to install node using the official binaries. Seems like it would be a simple extraction to a directory of my choice, and an addition to the path in my .zshrc? |
Seems like the permissions are all right. I don't see anything strange.
Yes, pretty much It's weird because the permission denied is for a rename, not a file created, not a delete. I searched really quick about this on google and found this that points to an issue in WSL that should be fixed in WSL2. Can you try it in a WSL2 environment? We don't actively support WSL, but it would be rather nice to have it working |
I just installed Node.js with [...]
npm notice New minor version of npm available! 7.13.0 -> 7.14.0
npm notice Changelog: https://github.com/npm/cli/releases/tag/v7.14.0
npm notice Run npm install -g [email protected] to update!
npm notice
» which npm
/Users/jlumbroso/.asdf/shims/npm
» npm --version
7.13.0
» npm install -g [email protected]
npm notice
npm notice New minor version of npm available! 7.13.0 -> 7.14.0
npm notice Changelog: https://github.com/npm/cli/releases/tag/v7.14.0
npm notice Run npm install -g [email protected] to update!
npm notice
npm ERR! code EEXIST
npm ERR! path /Users/jlumbroso/.asdf/installs/nodejs/16.2.0/.npm/bin/npx
npm ERR! EEXIST: file already exists
npm ERR! File exists: /Users/jlumbroso/.asdf/installs/nodejs/16.2.0/.npm/bin/npx
npm ERR! Remove the existing file and try again, or run npm
npm ERR! with --force to overwrite files recklessly.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/jlumbroso/.npm/_logs/2021-05-26T04_55_22_211Z-debug.log If |
I am on macos Big Sur, but I was able to successfully upgrade/install |
@augustobmoura Sorry for falling off of this.
I have tried it in WSL 2 (though it's Ubuntu 20) and it's working great. Updates still give the same issue. The linked issue from WSL could certainly be relevant, though I'm not using VSCode or really running anything from WSL at the time the failures happen. I'm basically using it for git at this point. |
Thanks for all the hard work on this plugin, it's been great for me!
I have an issue that I believe is partially related to WSL1 with Ubuntu 18.04. I'm unable to update npm using the built-in upgrade method of
npm i -g npm
.I get the following stack trace:
I also have Ubuntu 20 running on WSL2 and npm updates fine using asdf in that environment, both running the same nodejs version.
Does anyone have any ideas on what could be happening? Obviously, there is an issue with renaming the files. I did try restarting my computer and running only the WSL1 terminal.
The text was updated successfully, but these errors were encountered: