You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
node 7.0.0, MODULE_NOT_FOUND internal/fs during npm install #9355
That’s weird, there should be no /usr/local/lib/node_modules/npm/node_modules/cmd-shim/node_modules/graceful-fs at all – how/from where did you install npm?
I wiped everything in /usr/local/lib/node_modules and reinstalled and now it works fine. Thanks for rubber ducking guys!
Reacted by Gibson Fahnestock, Kai Dorschner, starshine, Roman Hotsiy, chris-eduardo, Adam Poczatek, Ronny Orbach, Haifeng Zhang, Mike Griffith, anthony webster and 21 more
[Solved] In my case, I installed node7 with .pkg in my Mac, and occurred the same error. Then I removed the /usr/local/lib/node_modules but find npm gone. Finally, I installed with .pkg again, and the issue cleared. Hope it helps to someone.
Reacted by Stephane Moracchini, Andy Chang, Umar Yusuf Dayyabu and Juanma Molina
For me removing the /usr/local/lib/node_modules/npm directory and then switching with n between an old version and back to the stable version solved the issue, that way, there is no need for cleaning the entire node_modules directory.
Reacted by Andrew Quan, John Bryson, Virgil B., Darien Maillet Valentine, Erik, Johnny Walker, Jesse Desaever, Ryan Cole, Michael McMillan, Alex Ilyaev and 6 more
I ran into this same problem installing with brew.
After deleting /usr/local/lib/node_modules as well as my local projects node_modules directory, and reinstalling node, I still had the issue.
this seems to be an issue with gulp requiring an old versions of graceful-fs
npm WARN deprecated graceful-fs@1.2.3: graceful-fs v3.0.0 and before will fail on node releases >= v7.0. Please update to graceful-fs@^4.0.0 as soon as possible. Use 'npm ls graceful-fs' to find it in the tree.
I solved by first renaming npm folder to npm_todelete folder in C:\Users\xxx\AppData\Roaming\npm\node_modules dir
And then run npm i -g npm@4.
New npm folder will be and npm_todelete can be deleted!
I got this issue when I updated my node version to v7.9.0, And solved it via update gulp from gulp@3.8.11 to gulp@3.9.1. So seems like it matchs what @hanakin described.
Upgrading to a newer version of Gulp fixed this for me when all the other solutions failed. Also note that the Gulp install said this:
"graceful-fs v3.0.0 and before will fail on node releases >= v7.0. Please update to graceful-fs@^4.0.0 as soon as possible. Use 'npm ls graceful-fs' to find it in the tree."
Step 2 : in package.json, i have changed request to latest version(2.83.0) which is higher than wanted version. so npm ERR! code MODULE_NOT_FOUND has came.
i did npm repair from control panel to solve this issue.
I also had this problem. The following steps are the causes for the
problem.
Step 1 : Executed the command npm outdated
C:\Program Files\nodejs\node_modules\npm>npm outdated
Package Current Wanted Latest Location
request 2.81.0 2.81.0 2.83.0 npm
Step 2 : in package.json, i have changed request to latest version(2.83.0)
which is higher than wanted version. so npm ERR! code MODULE_NOT_FOUND has
came.
i did reinstall to solve this issue.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#9355 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAWOk4H_aBqjYQkCLBC0DieY4ke7zWicks5spK0XgaJpZM4KkHV5>
.
For what it's worth (OS X 10.11.6) with a recently-updated Node.js (8.6.0), my previous gulp-related project then failed its "gulp serve" with the indicated error message.
cat package.json |grep gulp
"gulp": "^3.8.5",
npm uninstall gulp --save-dev
Using nano, manually added that line above back into package.json under devDependencies section
npm install
It now works as expected. Note that I didn't upgrade my gulp, I just re-installed it locally in place.
The same problem occurs when you switch Node 7 ++.
Solution: When you switch Node (version >7), the npm directory (/usr/local/lib/node_modules/npm) is deleted first, so that no problem occurs.
Activity
addaleax commentedon Oct 29, 2016
That’s weird, there should be no
/usr/local/lib/node_modules/npm/node_modules/cmd-shim/node_modules/graceful-fsat all – how/from where did you installnpm?ralphtheninja commentedon Oct 29, 2016
I'm using
nto install my node versionsaddaleax commentedon Oct 29, 2016
There is no such file in the
v7.0.0tarball either, which is whatnusually uses… are you sure you are usingnpmas it is packaged with Node?ralphtheninja commentedon Oct 29, 2016
Related issue https://gist.github.com/suissa/528c3e9e264f23378c2b0d36571de2dc (Also seem to use
n)ralphtheninja commentedon Oct 29, 2016
Which version of npm should be installed with node 7.0.0? Is 3.10.8 correct?
gibfahn commentedon Oct 29, 2016
@ralphtheninja Yep: https://github.com/nodejs/node/blob/v7.0.0/deps/npm/package.json#L2
ralphtheninja commentedon Oct 29, 2016
I wiped everything in
/usr/local/lib/node_modulesand reinstalled and now it works fine. Thanks for rubber ducking guys!hustshawn commentedon Jan 6, 2017
[Solved] In my case, I installed node7 with
.pkgin my Mac, and occurred the same error. Then I removed the/usr/local/lib/node_modulesbut findnpmgone. Finally, I installed with.pkgagain, and the issue cleared. Hope it helps to someone.pr-201 commentedon Jan 6, 2017
helped total reinstall nodeJS.
bollogo commentedon Jan 20, 2017
For me removing the /usr/local/lib/node_modules/npm directory and then switching with n between an old version and back to the stable version solved the issue, that way, there is no need for cleaning the entire node_modules directory.
AndrewEQ commentedon Jan 24, 2017
I did a similar thing to @bollogo:
rafaellavm commentedon Jan 25, 2017
I had the same problem, so I decided to delete the version 7.0 and install the older version, 6. So i solved this problem
6 remaining items
wmill commentedon Feb 23, 2017
If you installed using
ntry removing~/n/lib/node_modulesWirone commentedon Mar 21, 2017
I ran into the same issue on Windows after installing Node 7.7.3 into previous' installation folder (0.12.*).
npminstalled with installer was 4.1.2, so I've downloaded newestnpm(4.4.1) from registry and unpacked it into Node'snode_modules. It works now :-)stsmurf commentedon Mar 22, 2017
I ran into this same problem installing with brew.
After deleting
/usr/local/lib/node_modulesas well as my local projects node_modules directory, and reinstalling node, I still had the issue.Deleting
~/.nodefixed the issue.hanakin commentedon Mar 27, 2017
this seems to be an issue with gulp requiring an old versions of
graceful-fsnpm WARN deprecated graceful-fs@1.2.3: graceful-fs v3.0.0 and before will fail on node releases >= v7.0. Please update to graceful-fs@^4.0.0 as soon as possible. Use 'npm ls graceful-fs' to find it in the tree.kyawthetkt commentedon May 3, 2017
I solved by first renaming npm folder to npm_todelete folder in C:\Users\xxx\AppData\Roaming\npm\node_modules dir
And then run npm i -g npm@4.
New npm folder will be and npm_todelete can be deleted!
luochen1990 commentedon May 8, 2017
I got this issue when I updated my node version to v7.9.0, And solved it via update gulp from gulp@3.8.11 to gulp@3.9.1. So seems like it matchs what @hanakin described.
nattyman commentedon May 9, 2017
Upgrading to a newer version of Gulp fixed this for me when all the other solutions failed. Also note that the Gulp install said this:
"graceful-fs v3.0.0 and before will fail on node releases >= v7.0. Please update to graceful-fs@^4.0.0 as soon as possible. Use 'npm ls graceful-fs' to find it in the tree."
RichardDavid commentedon Aug 4, 2017
Just upgrade node version using nvm and it should solve this issue.
arpho commentedon Aug 21, 2017
same problem,I did like bollogo and it worked
earth-the-home commentedon Oct 5, 2017
I also had this problem. The following steps are the causes for the problem.
Step 1 : Executed the command npm outdated
C:\Program Files\nodejs\node_modules\npm>npm outdated
Package Current Wanted Latest Location
request 2.81.0 2.81.0 2.83.0 npm
Step 2 : in package.json, i have changed request to latest version(2.83.0) which is higher than wanted version. so npm ERR! code MODULE_NOT_FOUND has came.
i did npm repair from control panel to solve this issue.
arpho commentedon Oct 5, 2017
lunow commentedon Nov 3, 2017
On my system an old npm version caused the problem. Reinstall with
fixed it.
OutsourcedGuru commentedon Nov 28, 2017
For what it's worth (OS X 10.11.6) with a recently-updated Node.js (8.6.0), my previous gulp-related project then failed its "gulp serve" with the indicated error message.
"gulp": "^3.8.5",
It now works as expected. Note that I didn't upgrade my gulp, I just re-installed it locally in place.
zhuziyi1989 commentedon Mar 28, 2018
当切换 Node 7 ++,就会出现同样问题。
解决方案:在切换Node(版本>7)时,会先删除npm目录(/usr/local/lib/node_modules/npm),这样就不会出现问题了。
The same problem occurs when you switch Node 7 ++.
Solution: When you switch Node (version >7), the npm directory (/usr/local/lib/node_modules/npm) is deleted first, so that no problem occurs.
rm -rf /usr/local/lib/node_modules/npm