-
Notifications
You must be signed in to change notification settings - Fork 62
Upgrade NAN for Node 4.0.0 #180
Comments
@kkoopa - is this something you can help with? If not, is there an upgrade guide floating around, or should I work my way through the NAN changelog? |
Is it still going to be maintained? Would it not be better to write something on the javascript level that uses the existing code for versions less than 0.12, and the revised vm module of Node for everything later. Upgrading to NAN 2 wouldn't be hard, I can do it in ten minutes, but is it worth it? |
The problem is there's no way to write in package.json "install this module only in Node<4.0.0". You can declare it as an optional dependency but it will then try to get compiled in newer Nodes & fail; everything should work afterwards but the installation shouldn't have to try to compile things that are not needed, burning CPU cycles & printing confusing error-not-error messages. |
Ah, I had not thought about that, but it is easily avoidable. Hide everything behind an ifdef and make it compile nothing. |
Adding to the list: nodejs/node#2798. |
It might make sense to use the built-in vm module already from 0.12 up, since @domenic based the rewrite on Contextify. I would think many bugs that were in Contextify have been fixed in the vm module in that process. Essentially, the C++ code of Contextify is only necessary for Node 0.10 and older. |
+1 |
+1 actually one of our projects completely won't work on node 4.x just because of this... |
sorry, I'm blocked on one failure in #181 and don't have time to figure it out right now, happy for someone else to take my code if they can work it out |
+1 It's affects a lot of packages i need since upgrading to node 4.x. It appears Browser Sync and a few of its plugins require it. |
+1 Breaks lots of things |
Using node 4.1.0 $ npm install contextify
CXX(target) Release/obj.target/contextify/src/contextify.o |
If you're desperate then you can |
If finishing up the nan2 branch proves difficult to finish fast maybe @kkoopa's solution from #180 (comment) would work? |
I'm not using contextify directly--its used by several other modules like
|
Just a comment to be in touch Thanks for your work guys 👍 |
So clearly not a fix, but if you're deploying to Heroku just force Node 0.12.7 in the package.json file for your project until the 4.x support is resolved. Worked for me though I don't have any Node 4.0/4.1 dependencies at this time. "engines": {
"node": "0.12.7",
"npm": "2.11.3"
}, I mention Heroku as this defect was blocking new deploys for me due to a recent Heroku Node upgrade. |
+1 |
+1 for node 4.x support. |
I'm really looking forward to knowing what we'll be able to buy with all these +1's |
+1 |
4 similar comments
👍 |
+1 |
+1 |
+1 |
+1 |
+111111111111111111111111111111111111111 |
+1 |
6 similar comments
+1 |
+1 |
+1 |
+1 |
+1 |
+1 |
This fixed it for me for now - thanks @sirbrillig: sirbrillig/jsdom@b30bc08 |
Needs a few more +1s |
(Fixed in 0.1.15) |
+thanks |
No description provided.
The text was updated successfully, but these errors were encountered: