Live data from Hacker News

Node.js 5.0 Released

github.com

111–120 of 132 posts

Re: Node.js 5.0 Released

#111

I'm not sure why so many people are freaking out. Looking at the changelog, it looks like they decided to commit a bunch of breaking changes that were previously marked as deprecated. If your code was running before without warnings, upgrading shouldn't have a negative impact. The pace of change is fast because node ES6 support is progressing fast enough to maintain near 1:1 feature parity with v8. A bunch of ES6 fea…

> I'm not sure why so many people are freaking out. Probably because you don't use any binary packages that haven't even made it to 4.x yet. My app requires one so I'm still stuck on node 0.12 until they update. I've filed a bug report but before they could even respond 5.0 is out. Not they have a quandary: do they support 4.x or 5.x when they update? Npm doesn't support forks, so they can't get one version for users…

[deleted]

Re: Node.js 5.0 Released

#112
post #108

Earlier quoted context omitted.

javascript pace feels so overwhelming it makes me enjoy reading Java 6 specs.

You jest, but this week i've been developing my first java web app using play framework, coming from a decade of PHP and javascript, and i found the experience surprisingly nice. You can get a good edit-refresh cycle going using incremental recompilation, and the api's are elegant and flexible. My preconceived notions of the verbosity and ugliness of java web app code proved unfounded.

Java was heavy, and still is but most of the perceived weight came from immaturity (the world wanted freeform template oriented scripts). Now all languages are moving towards types, packages/modules, conventions and structures. If a php3 dev discovers php 5.6 I'm sure he wouldn't enjoy it.

Re: Node.js 5.0 Released

#113
post #7

I recently looked at using Node for a simple API backend. ES6 seems like it's not there yet, the stability of Node makes me wary. Constant changes seem exhausting to keep up with. For a simple microservice api you don't want to be upgrading it every 3 days. The continuous change doesn't make sense to me. Trying to get up to speed on all the Node.js ecosystem feels exhausting, only to have it change a few weeks later.…

As an engineer, I assume you use a programming language and the libraries from its ecosystem to solve problems. Unless the latest features are essential to solving your problems, I would say this is unnecessary worry.

We use both ES5 and ES6 (via transpilation) where I work. I had to write a lot of the tooling to support ES6 because a lot of front-end engineers were asking for ES6. To this day, I have yet to hear one engineer justify their "need" for ES6 with one of the features that make something easy that is hard or cumbersome with ES5. Pretty much every feature engineers were wanting to use were simple sugary syntax features like the spread operator that is trivially dealt with with a library like `xtend` (the irony is seeing these same engineers continue to use _.each on arrays instead of Array.prototype.forEach)

There is a corollary to Wadler's Law in here somewhere: https://wiki.haskell.org/Wadler's_Law

    In any debate on the merits of migrating to ES6, the 
    total number of times an ES6 feature is cited as 
    justification to migrate to ES6 is proportional to two
    raised to the power of its position.
           0. Semantic features
           1. Syntax features
           2. Lexical syntax features
           3. Lexical syntax of comments features

Re: Node.js 5.0 Released

#114
post #89

We use node on Windows for our asset minifiers, hopefully the new version of NPM will make this a little more pleasant! Your dependencies will now be installed maximally flat. Insofar as is possible, all of your dependencies, and their dependencies, and THEIR dependencies will be installed in your project's node_modules folder with no nesting. You'll only see modules nested underneath one another when two (or more) m…

Maybe Microsoft wakes up to fix the MAXPATH limit (260 chars). Recently the improved UI of the environment variable dialog, after 25 years.

Many (most? all?) windows apis that take absolute paths can take extended length paths. Extended length paths (just add \\?\ to the front of your normal local path, or \\?\UNC to the front of your UNC paths) allow up to 32K paths.

I'm not really sure why node doesn't use them internally to solve the issue.

Re: Node.js 5.0 Released

#115

We use node on Windows for our asset minifiers, hopefully the new version of NPM will make this a little more pleasant! Your dependencies will now be installed maximally flat. Insofar as is possible, all of your dependencies, and their dependencies, and THEIR dependencies will be installed in your project's node_modules folder with no nesting. You'll only see modules nested underneath one another when two (or more) m…

You can use npm@3 without upgrading node - we use npm@3 and node 0.10 at work, although we mainly use it for out build tools and haven't migrated out node microservices - yet.

Re: Node.js 5.0 Released

#116

I'm not sure why so many people are freaking out. Looking at the changelog, it looks like they decided to commit a bunch of breaking changes that were previously marked as deprecated. If your code was running before without warnings, upgrading shouldn't have a negative impact. The pace of change is fast because node ES6 support is progressing fast enough to maintain near 1:1 feature parity with v8. A bunch of ES6 fea…

> I'm not sure why so many people are freaking out. Probably because you don't use any binary packages that haven't even made it to 4.x yet. My app requires one so I'm still stuck on node 0.12 until they update. I've filed a bug report but before they could even respond 5.0 is out. Not they have a quandary: do they support 4.x or 5.x when they update? Npm doesn't support forks, so they can't get one version for users…

>The only sensible way to fix this that I can think of is to build in an extension layer into node so that binary packages don't use raw v8 APIs (since those seem to change a lot). Then that layer can be made (more) stable, even in the face of constant v8 upgrading.

That already exists, it's called nan: https://github.com/nodejs/nan

Re: Node.js 5.0 Released

#117
post #76
post #63

Earlier quoted context omitted.

hey! do you have a specific problem in mind or is this just a hypothetical musing? 'cause the actual changes that break between npm 1 and 2 are very small. (the changes to npm run, mostly, and the cache.) so it's Very Strange(tm) modules that break, and the new run behavior is much more useful - npm team member

Is there / could there be an option in package.json for which Node version you support? Like, v1.0.0 of my lib supports up to and including Node 4.2.1, but v2.0.0 requires Node 5? That way people would get a working version relatively seamlessly. I realise this makes the package.json Node-specific, which might be something you want to avoid. EDIT: to part-answer my own question, package.json has the "engines" field.…

[deleted]

Re: Node.js 5.0 Released

#120

And it still uses OpenSSL as a CSPRNG, rather than the operating system's CSPRNG (CryptGenRandom, /dev/urandom, etc.). I guess maybe they'll fix that in 6?

And use what in Windows? A closed-source CSPRNG? Has there ever been a serious vulnerability/problem found with OpenSSL's CSPRNG? I'm actually curious as to why this is an issue.
Post reply on HN