Muthukumar Marichamy
Muthukumar Marichamy

Reputation: 1214

Got error in Node JS when it downgrade node version or npm version

My application in windows machine does run only the node version of v6.11.0 and NPM is 3.11.11.

Now, my node version and NPM have been upgraded. I am not able to download the node version and NPM version. Current version of node is v10.14.1 and npm is 5.5.1

When I tried to downgrade, I am facing the below error.

npm install -g [email protected]
npm install -g [email protected]

Below error

npm WARN npm npm does not support Node.js v10.14.1
npm WARN npm You should probably upgrade to a newer version of node as we
npm WARN npm can't make any promises that npm will work with this version.
npm WARN npm Supported releases of Node.js are the latest release of 4, 6, 7, 8.
npm WARN npm You can find the latest version at https://nodejs.org/
WARNING: You are likely using a version of node-tar or npm that is incompatible with this version of Node.js.
Please use either the version of npm that is bundled with Node.js, or a version of npm (> 5.5.1 or < 5.4.0) or node-tar
(> 4.0.1) that is compatible with Node.js 9 and above.
npm[9256]: src\node_zlib.cc:441: Assertion `args.Length() == 7 && "init(windowBits, level, memLevel, strategy, writeResu
lt, writeCallback," " dictionary)"' failed.
 1: 00007FF63013ECF5
 2: 00007FF6301181A6
 3: 00007FF630118271
 4: 00007FF6300740B6
 5: 00007FF630943BA2
 6: 00007FF63094503D
 7: 00007FF630944099
 8: 00007FF630943F7B
 9: 000002EA035DC5C1

Any idea that how to resolve the error which I faced.

Upvotes: 3

Views: 4026

Answers (3)

Rohan Mathew Alex
Rohan Mathew Alex

Reputation: 123

npm i -g npm@add version which you need to rollback.

eg: npm i -g [email protected]

Then check your version:

npm -v

i - install g - globally

Upvotes: 1

Venu
Venu

Reputation: 475

I installed the Node v10.14.1 and encountered the same error while installing a package.

I tried to uninstall and reinstall; but did not solve the problem. The installation of Node.js did not update/upgrade the "npm" version.

Then I followed below steps to fix the problem.

  1. Go to "C:\Users\\AppData\Roaming" and delete the "npm" folder.
  2. Repair the Node.js installation (you could also reinstall it)

I hope this will help to resolve the issue.

Upvotes: 1

Muthukumar Marichamy
Muthukumar Marichamy

Reputation: 1214

I uninstalled the current node and installed nvm https://github.com/coreybutler/nvm-windows

Upvotes: 1

Related Questions