balderdashy / sails

Realtime MVC Framework for Node.js
https://sailsjs.com
MIT License
22.85k stars 1.95k forks source link

Grunt issue on sailslift - error: Grunt :: (node:6532) fs: re-evaluating native module sources is not supported. #3715

Closed gustavLatte closed 8 years ago

gustavLatte commented 8 years ago

Sails version: 0.12.3 Node version: 6.0.0 NPM version: 3.8.6 Operating system: Windows 10 64bit


Hi,

I just upgraded node to it's latest version (6.0.0) and when lifted my sails app i got this error:

error: Grunt :: (node:6532) 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.

Any ideas what it could be?

stevestock commented 8 years ago

Why is this closed. The linked issue is closed too.

I am having this problem as well.

jimior2 commented 8 years ago

got same problem here.

sgress454 commented 8 years ago

Sorry all, seems like my previous comment didn't post for some reason.

The error message is a little cryptic, but it says it all: the module in question is probably not compatible with Node 6. You can try wiping your node_modules folder, then doing npm cache clean followed by npm install to see if it helps, but the only real solution until new versions come out is probably to downgrade your Node version to something less bleeding edge, or remove the watch task from tasks/register/default.js.

gustavLatte commented 8 years ago

Thanks @sgress454 for me i think i'll just remove the watch task as I kind of researching with Node 6.

jamilnyc commented 8 years ago

For anyone else that stumbles on this. I noticed that I don't get the error when lifting as root sudo sails lift

iustin-nita commented 8 years ago

Same problem here.

merianos commented 8 years ago

Me too ...

hgwood commented 8 years ago

This is a warning that the program will break in Node 7. See https://github.com/nodejs/node/pull/5102. A dependency is probably using graceful-fs@<4.

ktravelet commented 8 years ago

I'm having this problem as well. This seems to be causing grunt to not inject the dependency files now. Is anyone else having that problem?

running 'npm update graceful-fs' doesnt do anything. I'm thinking updating the top level npm packages will help with the following:

npm update grunt npm update grunt-contrib-watch

any thoughts before I do this and break my system?

npm ls graceful-fs ├─┬ grunt@0.4.5 │ └─┬ glob@3.1.21 │ └── graceful-fs@1.2.3 ├─┬ grunt-contrib-less@1.1.0 │ └─┬ less@2.5.3 │ └── graceful-fs@3.0.8 ├─┬ grunt-contrib-uglify@0.7.0 │ └─┬ maxmin@1.1.0 │ └─┬ pretty-bytes@1.0.4 │ └─┬ meow@3.7.0 │ └─┬ read-pkg-up@1.0.1 │ └─┬ read-pkg@1.1.0 │ ├─┬ load-json-file@1.1.0 │ │ └── graceful-fs@4.1.4 │ └─┬ path-type@1.1.0 │ └── graceful-fs@4.1.4 ├─┬ grunt-contrib-watch@0.5.3 │ └─┬ gaze@0.4.3 │ └─┬ globule@0.1.0 │ └─┬ glob@3.1.21 │ └── graceful-fs@1.2.3 └─┬ sails@0.12.3 -> /usr/local/lib/node_modules/sails ├─┬ express-handlebars@3.0.0 eful-fs@4.1.4 ├─┬ fs-extra@0.18.4 │ └── graceful-fs@3.0.8 ├─┬ grunt@0.4.5 │ └─┬ glob@3.1.21 │ └── graceful-fs@1.2.3 ├─┬ grunt-contrib-less@1.1.0 │ └─┬ less@2.5.3 │ └── graceful-fs@3.0.8 └─┬ grunt-contrib-watch@0.5.3 └─┬ gaze@0.4.3 └─┬ globule@0.1.0 └─┬ glob@3.1.21 └── graceful-fs@1.2.3

icodeforlove commented 8 years ago

having the same issue

node v6.0.0 sails v0.12.3

mounirn commented 8 years ago

same issue with node v6.2.0 and sails v0.12.3

VirtualWolf commented 8 years ago

Yep, same problem too, same versions as @mounirn. Makes me sad because I want to use Node 6 to get all the shiny new ES6 features that 5.x doesn't support. :(

hgwood commented 8 years ago

@VirtualWolf Help sails upgrade to grunt 1.0 and grunt-contrib-watch 1.0. That should fix the problem. :)

kiesman99 commented 8 years ago

Hello guys I solved this problem on my PC :)

Just install this package: https://www.npmjs.com/package/npm-check-updates

then go into your sails project and type in

ncu

You'll see all the modules you can update. To update them type in

ncu -u npm install

And it's done :)

cburatto commented 8 years ago

@kiesman99 thumbs up -- worked here

parnurzeal commented 8 years ago

@kiesman99 working! thx!

ChALkeR commented 8 years ago

Hi. sails is currently #16 in my list of modules that would likely to be broken when https://github.com/nodejs/node/pull/6413 lands (which is anticipated to happen before v7.0).

Note that graceful-fs@1 and graceful-fs@4 are ok and would not be broken by this, but a require() on graceful-fs@2 or graceful-fs@3 would cause an error soon.

That is, runtime warning fs: re-evaluating native module sources is not supported. would be turned into a throw.

If you or your deps use graceful-fs@2 or graceful-fs@3 in runtime — you are affected.

Tracking: https://github.com/nodejs/node/issues/5213.

@sgress454, does this still need more info?

ChALkeR commented 8 years ago

@ktravelet Note that graceful-fs@1 do not trigger the runtime warning and would not be affected. The runtime warning is caused by graceful-fs@3.0.8 here.

sgress454 commented 8 years ago

@ChALkeR do you still get this with the latest on master (published as sails@beta)? All the relevant dependencies should be updated.

ChALkeR commented 8 years ago

@sgress454 Good to know, thanks! I don't personally use sails, and I tested only the @latest of everything. Any ETA? Node.js 7.0 is going to be released in autumn, so the breakage won't happen until then.

davoscript commented 7 years ago

Hey, just in case anyone is checking this. Latest sailsjs version is using grunt 1.0.0 which solved the problem for me.

I updated sails, then created a new temp project and copied the package.json dependencies to my project.