Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to fix 'fs: re-evaluating native module sources is not supported' - graceful-fs

I had this problem and I was able to fix this by updating npm

sudo npm update -g npm

Before the update, the result of npm info graceful-fs | grep 'version:' was:

version: '3.3.12'

After the update the result is:

version: '3.9.3'

Type npm list graceful-fs and you will see which versions of graceful-fs are currently installed.

In my case I got:

npm list graceful-fs

@request/[email protected] /projects/request/promise-core
+-- [email protected]
| `-- [email protected]
|   +-- [email protected]
|   | `-- [email protected]
|   |   `-- [email protected]
|   |     `-- [email protected]
|   |       `-- [email protected]        <==== !!!
|   `-- [email protected] 
`-- [email protected]
  +-- [email protected]
  | `-- [email protected]
  |   `-- [email protected]
  |     `-- [email protected]
  |       `-- [email protected] 
  `-- [email protected]
    `-- [email protected]
      `-- [email protected]

As you can see gulp deep down depends on a very old version. Unfortunately, I can't update that myself using npm update graceful-fs. gulp would need to update their dependencies. So if you have a case like this you are out of luck. But you may open an issue for the project with the old dependency - i.e. gulp.


Solved this bug with reinstall gulp

npm uninstall gulp
npm install gulp

Deleting node_modules folder contents and running

npm install bower
npm install

solved the problem for me!


As described here, you can also attempt the command

npm cache clean

That fixed it for me, after the other steps had not fully yielded results (other than updating everything).