简体   繁体   中英

graceful-fs warning when running Grunt task

I'm getting this warning when running one of my grunt tasks:

Warning: (node:2771) fs: re-evaluating native module sources is not supported. If you are using the graceful-fs module, please update it to a more recent version.

Does somebody know how to get rid of that? And how to find it's source? My nodejs version is 6.0.0.

Your best option right now is to downgrade to the latest Node 5.x until that dependency has been updated.

Suggest that you read: DON'T rush to upgrade to Node v6 and Breaking changes between v5 and v6 .

We all want to be on the latest and greatest - myself included. A great way to do this is to use something like n or nvm to quickly flip between Node versions so that we can use Node v6 on some projects and older versions on other projects.

The other thing that I do is I put a package like Node Version Checker in my project and use it in both the tests and the application to make sure that I've changed to the expected version of Node when I start the project or the tests as we often forget to flip to the right version of Node if we have multiple versions on multiple projects.

If you're using homebrew here is how you can downgrade to v5.11.0

brew tap homebrew/versions
brew unlink node
brew install homebrew/versions/node5

And you're good to go.

after update to node6 have the same issue. working workaround downgrade, eg nvm use v5.11.0

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM