News for hackers. Stuff that matters.
Re:Yarn – A new package manager for JavaScript by jsight on Tuesday October 11, 2016 @02:35PM (#12687255)
In fairness to the language and tools, this seems to be more of a cultural problem than anything.

You can do the same kind of version range tricks in typical Java builds, for example (Maven), but most people hardcode the values to keep builds as deterministic as possible.

For some reason, the JS community seems to prefer just trusting that new versions won't break anything. Its either very brave of them really (or maybe just foolish).

Re:Yarn – A new package manager for JavaScript by deckard1 on Tuesday October 11, 2016 @11:10PM (#12690195)
> the JS community seems to prefer just trusting that new versions won't break anything. Its either very brave of them really (or maybe just foolish).

Let's not pretend that we aren't all blindly tossing in random libs of dubious quality and origin we find on github into our package.json and hoping for the best anyway. My company talks a mean talk about "best practices", but, my god, the dependencies we use are a true horror show.

Re:Yarn – A new package manager for JavaScript by jakub_g on Tuesday October 11, 2016 @02:56PM (#12687460)
I hate non-reproducible builds and semver-relaxed dep-of-the-dep issues, but, while a broken dep fails the build for lots of people (downside), the upside of this is that very quickly (within hours of a new dep being published) there will be lots angry people complaining about it on GitHub, and a faulty dep will be typically quickly rolled back / superseded with a patch. Otherwise, some bugs might be sitting hidden for a long time.
Re:Yarn – A new package manager for JavaScript by mvindahl on Wednesday October 12, 2016 @01:42AM (#12690646)
But can yarn fix this?

Say that I use yarn to depend upon some module X, specifying a fixed version number like the good boy scout that I am. Module X resides on npmjs and in turn depends upon the bleeding edge version of module Y. And then one day module Y goes all Galaxy Note and bursts into flames.

Can yarn shield my app from that?

Re:Yarn – A new package manager for JavaScript by nilliams on Wednesday October 12, 2016 @02:37PM (#12695424)
Yes it claims to provide a lockfile while locks all your deps all the way down the dependency tree.

You can do (and are supposed to do) the same with npm's own shrinkwrap, but people claim that it doesn't work as intended.

Re:Yarn – A new package manager for JavaScript by dclowd9901 on Tuesday October 11, 2016 @08:54PM (#12689687)
It's not a cultural problem. People make mistakes. People don't know what a non-breaking change is, especially those not well versed in refactor work.

I don't think Yarn solves any of these problems, tbh. It seems like what we really need is a package manager that tests the api of each package update to make sure nothing in it has broken expectation in accordance with Semver.

Re:Yarn – A new package manager for JavaScript by jsight on Wednesday October 12, 2016 @05:23PM (#12696522)
It is a cultural problem in that people on other platforms (eg, Maven) don't choose floating dependency versions, generally.