Nvm-windows: NPM fails to download

Created on 14 Sep 2018  路  4Comments  路  Source: coreybutler/nvm-windows

My Environment

  • [X] Windows 10

I'm using NVM4W version:

  • [X] 1.1.5

I have already...

  • [X] read the README to be aware of npm gotchas & antivirus issues.
  • [X] reviewed the wiki to make sure my issue hasn't already been resolved.
  • [X] verified I'm using an account with administrative privileges.
  • [X] searched the issues (open and closed) to make sure this isn't a duplicate.
  • [X] made sure this isn't a question about how to use NVM for Windows, since gitter is used for questions and comments.

My issue is related to (check only those which apply):

  • [X] A standard shell environment (terminal/powershell)

Expected Behavior

NPM to download correctly

Actual Behavior

Installation log:

Downloading node.js version 10.10.0 (64-bit)...
Complete
Downloading npm version 6.4.1... Download failed. Rolling Back.
Rollback failed. remove C:\nvm\temp\npm-v6.4.1.zip:
The process cannot access the file because it is being used by another process.
Could not download npm for node v10.10.0.
Please visit https://github.com/npm/npm/releases/tag/v6.4.1 to download npm.
It should be extracted to C:\nvm\v10.10.0

The url for npm has changed and I believe that could be the problem. It's not "https://github.com/npm/npm/releases/tag/v6.4.1" but "https://github.com/npm/cli/releases/tag/v6.4.1".

I downloaded it manually but I believe it shouldn't be extracted to "C:\nvm\v10.10.0" but to "C:\nvm\v10.10.0\node_modules" instead. And If I extracted it as is, the name of the folder is cli-6.4.1 and I don't know if it is right or it should be cli or npm (without the version number).

Last node version I used was 8.11.1 and I didn't have a problem installing it a couple of month ago.

Steps to reproduce the problem:

Runing nvm install 10.10.0 in cmd

Thanks!

Most helpful comment

Duplicate of #373
You should update nvm4w to 1.1.7

All 4 comments

Duplicate of #373
You should update nvm4w to 1.1.7

Thanks. Sorry for the duplicate, I tried to search the issue with different wordings but that one didn't pop up :(

@leiamac no worries :)

Solution:

  • Download the relevant npm version from github.
  • Then extract it to (C:\Users\tharindu\AppData\Roaming\nvm\v10.20.1\node_modules\npm)
  • If npm bat file under (C:\Users\tharindu\AppData\Roaming\nvm\v10.20.1) - (I have copied it from working node version)
Was this page helpful?
0 / 5 - 0 ratings

Related issues

petrovicz picture petrovicz  路  4Comments

tomByrer picture tomByrer  路  4Comments

webspecialist picture webspecialist  路  5Comments

flpms picture flpms  路  4Comments

eliavmaman picture eliavmaman  路  6Comments