News for hackers. Stuff that matters.
Re:Flat Tree Dependency Resolution in Npm v3 by city41 on Thursday December 31, 2015 @11:55AM (#10818402)
Why do dev communities have to continually pay the Windows tax? If Microsoft keeps insisting on being an outlier in the world of OSes, shouldn't they be the ones burdened?

I gotta say, as someone who never ever uses Windows but maintains a couple of open source packages, I'm really sick of the Windows only problems that crop up.

Re:Flat Tree Dependency Resolution in Npm v3 by tvanantwerp on Thursday December 31, 2015 @12:01PM (#10818437)
As someone who has no choice but to use Windows at work, I'm really sick of all the problems that crop up because so many tools use were written by people who won't use Windows and haven't tested anything on it.
Re:Flat Tree Dependency Resolution in Npm v3 by tsuraan on Thursday December 31, 2015 @12:32PM (#10818593)
That's a funny point of view. Windows is made by a multi-billion dollar company, rented by countless wealthy software development shops, but it's volunteer open-source programmers who are supposed to take on the burden of supporting it? Seriously, I can't even comprehend that thought process.

I write software for fun, I release it on github, and some people find it useful. If there are other people who don't, they can improve it for their own purposes, or they can find or write something better. I don't think anybody has a right to expect me to support Microsoft's product. That's insane.

Re:Flat Tree Dependency Resolution in Npm v3 by Silhouette on Thursday December 31, 2015 @11:19PM (#10821086)
I don't think anybody has a right to expect me to support Microsoft's product. That's insane.

True enough, though it's also fair to consider a language/platform/ecosystem inferior for some work if it relies on that kind of individual and often less portable contribution for its effectiveness. A lot of FOSS advocates will promote community support and a broad contributor base as advantages of that style of development, but there is another side to that coin, which is that sometimes you get just what you (didn't) pay for and you're on your own in terms of support or working around any problems.

Re:Flat Tree Dependency Resolution in Npm v3 by saosebastiao on Thursday December 31, 2015 @12:13PM (#10818491)
If I had no choice but to use Windows at work, and using Windows meant I couldn't use a large amount of development tools that I rely on, then the last ones I would blame would be the open source developers that won't use or develop for Windows. Your employer is the problem here.
Re:Flat Tree Dependency Resolution in Npm v3 by krisdol on Thursday December 31, 2015 @12:14PM (#10818497)
Why do you expect developers to pay for software, OSes, and licenses they don't use in order to develop open source software for free? Help them out by contributing, or blame Microsoft who has the resources to make their own OS more compatible

Doesnt Microsoft have their own V8 or node.js fork now?

Re:Flat Tree Dependency Resolution in Npm v3 by ploxiln on Thursday December 31, 2015 @12:22PM (#10818535)
Kinda funny isn't it, after a decade where one might be required to use a proprietary VPN or email client that only runs on windows. And those things didn't use standard, published, or even consistent protocols, nor were they open-source. In fact they were hostile to compatible implementations. They had to be reverse-engineered.

So now you get just a little, watered-down taste of using the non-preferred platform for something.

Re:Flat Tree Dependency Resolution in Npm v3 by city41 on Thursday December 31, 2015 @12:13PM (#10818487)
I feel your pain, but am not convinced open source maintainers should have to be the ones to resolve the issue. Especially since so many projects are done using spare time and with no compensation.
Re:Flat Tree Dependency Resolution in Npm v3 by ag_dubs on Thursday December 31, 2015 @12:47PM (#10818668)
hi! i totally know this is a common feel for many npmjs users. this is why i've been running an empathy campaign for Windows, Windows Wednesday, where i do all my work (with/for npm) on windows. it's been good for finding bugs, either technical or UX. i'm working on improving the docs to make them friendlier to all platforms (not just OSX, which is the most common platform at npmjs).

npmjs cares about the enterprise + windows.

Re:Flat Tree Dependency Resolution in Npm v3 by city41 on Thursday December 31, 2015 @12:59PM (#10818737)
I think this is the wrong approach. We shouldn't pick up MS's slack, MS should. This just enforces the current situation and keeps enabling MS to ignore the problem.
Re:Flat Tree Dependency Resolution in Npm v3 by ag_dubs on Thursday December 31, 2015 @06:41PM (#10820361)
you might also consider the fact that OSX machines are expensive. and the education for learning linux is generally expensive or not accessible. so supporting windows also supports ... poor people, people from different countries that have different economies, etc.

should we not pick up capitalism's slack? capitalism sure isn't going to pick up its own slack, err... systemic method of restricting underprivileged/poor people's access to power.

Re:Flat Tree Dependency Resolution in Npm v3 by fapjacks on Friday January 01, 2016 @11:28PM (#10825032)
> the education for learning linux is generally expensive or not accessible

Wow, this is incredibly wrong. The cost of education to learn Linux is living in a country where you are likely to be literate and have access to a computer. That is literally the cost to learn Linux, guy. There is nothing like an MSDN subscription for Linux documentation.

Re:Flat Tree Dependency Resolution in Npm v3 by steveklabnik on Thursday December 31, 2015 @01:37PM (#10818918)
What problem is that? That they have a different operating system?

npm is also a bit different, in your objection: they're a company. Companies need users. Supporting more platforms to get more users seems like pretty much, well, business as usual.

Re:Flat Tree Dependency Resolution in Npm v3 by city41 on Thursday December 31, 2015 @01:47PM (#10818974)
That is a fair point. npm being a company does change the situation.
Re:Flat Tree Dependency Resolution in Npm v3 by gelasio on Thursday December 31, 2015 @01:22PM (#10818848)
So, are you of the opinion that OSS projects should never be built for any commercial, proprietary OS or just Windows (i.e. because it's not Unix)?

For instance - OS X window managers suck. Do you think that a project like Spectacle should have never been built because they're just picking up Apple's slack?

Re:Flat Tree Dependency Resolution in Npm v3 by city41 on Thursday December 31, 2015 @01:36PM (#10818914)
I don't see how a project like Spectacle, which is OSX specific, relates. If someone wants to make an OS specific project, more power to them. The issue arises on platforms that span OSes, and they just never quite span onto Windows correctly.

Microsoft is very happy that Node, Java, Clojure, etc work on Windows. It helps them a lot. But they make little to no effort to help bridge the gap, they usually leave that to everyone else. That's my gripe, right there.

And to be fair, this is not a black and white situation. It's complex and Microsoft's role in all of this is complex too. And sometimes this issue does crop up on other OSes, for example Docker on OSX is sometimes a little painful.

Re:Flat Tree Dependency Resolution in Npm v3 by gelasio on Thursday December 31, 2015 @02:07PM (#10819086)
"But they make little to no effort to help bridge the gap, they usually leave that to everyone else."

OK, but that's also where you're wrong, right there. In general, but also particularly for this exact issue - Microsoft considered attempting to fix the file path limit for the first release of Windows 10. Maybe you don't understand, but it's going to take a herculean effort to fix this. They want to do it and if you need proof of that I can find posts of them talking about what I just said.

Re:Flat Tree Dependency Resolution in Npm v3 by martindevans on Thursday December 31, 2015 @03:06PM (#10819391)
Don't UNC paths solve this problem already (30000+ char limit)?
Re:Flat Tree Dependency Resolution in Npm v3 by tracker1 on Thursday December 31, 2015 @06:46PM (#10820377)
The problem is the default/legacy APIs don't use the new paths... in .Net I had this problem a lot, and serious issues every method I tried to work around it would hard crash VS, let alone the application I was working on... in the end, after days trying the solution was to say f*ck it and just put the directory I was working with closer to the root of the drive in question.

Why they can't fix .Net under the covers to use UNC in windows to avoid the class of problem I don't know, understand or comprehend... and that's just one very common platform for windows. I would say the same for npm/node and libuv for that matter.

I use bash a lot in windows (installed with msysgit), and that's got it's own set of problems. More problematic is the number of node modules that rely on bash scripts for builds, that don't work at all in windows.... which makes it very hard to contribute.

Re:Flat Tree Dependency Resolution in Npm v3 by nawitus on Thursday December 31, 2015 @03:06PM (#10819390)
I believe Microsoft worked to get Node.js supported on Windows.
Re:Flat Tree Dependency Resolution in Npm v3 by steveklabnik on Thursday December 31, 2015 @04:26PM (#10819776)
Not just that, but they're working on making Node work with Chakra.
Re:Flat Tree Dependency Resolution in Npm v3 by Touche on Thursday December 31, 2015 @04:36PM (#10819824)
Can they make it so I can spawn a process and not worry about whether I'm spawning on unix or Windows?
Re:Flat Tree Dependency Resolution in Npm v3 by steveklabnik on Saturday January 02, 2016 @01:59PM (#10827351)
I don't know it at that level of detail.
Re:Flat Tree Dependency Resolution in Npm v3 by Maarten88 on Thursday December 31, 2015 @04:13PM (#10819710)
Yes, npm is very problematic/buggy on Windows. I wasted many hours because of https://github.com/npm/npm/issues/9696 (meaning any build on visual studio online breaks ~50% of the time simply running 'npm install').

Microsoft should finally fix the MAX_PATH issue in Windows, but npm should just fix their software: it's too important to be that buggy.

Re:Flat Tree Dependency Resolution in Npm v3 by gelasio on Thursday December 31, 2015 @01:05PM (#10818766)
It sounds like you're getting annoyed that the devs of certain projects like Node.js have chosen to support an OS that you don't use without asking you about it first... If you're in control of the project - you have every right to ignore Windows users. If you're not in control, then you really have zero right to complain. Zero.

Devs certainly aren't forced to "pay the Windows tax" in any way. Plenty of OSS projects completely ignore Windows. I'm sure you're aware though that Windows has the majority market share of desktop operating systems. If your software is interesting to the vast, vast population of Windows users, you might get some requests to support Windows. And since it's not an outlier in the market, other desktop OSes should obviously strive to be more like Windows ;)

Re:Flat Tree Dependency Resolution in Npm v3 by city41 on Thursday December 31, 2015 @01:22PM (#10818840)
Windows is very much an outlier in the world of software development. Unless you're specifically using Microsoft tech (ie .NET and all that), then you're in a world dominated by Linux and OSX.

I'm annoyed that Microsoft insists on going forward with a proprietary OS that does not conform to standards that pretty much every single other OS does. Sure, platform specific issues do happen for other OSes, but they are rare. They are extremely common for Windows.

For sure, I have no obligation to fix Windows specific issues in my projects. All of my projects are done in my spare time and given away for free. But Windows specific issues are still annoying and disappointing.

Another aspect of this that is annoying is that major, mission critical open source projects have to dedicate so many resources to Windows. For example this bug in ClojureScript: https://github.com/clojure/clojurescript/commit/80d46bdb7969...

Imagine if the Clojure team didn't have to worry about file separator differences, and the multitude of other Windows annoyances. How much extra energy, time and resources would they gain? I suspect a lot.

EDIT: And I would also say I have every right to complain about Microsoft. Ignoring standards and doing their own thing for their own financial gain at everyone else's expense is definitely worthy of complaint. Also see Internet Explorer.

Re:Flat Tree Dependency Resolution in Npm v3 by moron4hire on Thursday December 31, 2015 @02:35PM (#10819222)
>> Windows is very much an outlier in the world of software development. Unless you're specifically using Microsoft tech (ie .NET and all that)

I think you need to get out more. Or at least go to meetups that don't only meet at coffee shops. You're cutting out a huge chunk there, and there are still huge chunks that use Windows to do Java, C++, etc.

I mean, game development is a multi billion dollar industry that is almost exclusively Windows-but-not-.NET, outside of consoles, and even on consoles it's still Windows in a large number of cases.

>> I'm annoyed that Microsoft insists on going forward with a proprietary OS that does not conform to standards that pretty much every single other OS does.

This is different from Apple with OSX and iOS how? This is different from Google with Android how? This is different from Canonical with Unity how? This is different than RedHat and Debian and pretty much every other major Linux distro with systemd how?

And for crying out loud, file separator issues? That's not even a hard one.

Re:Flat Tree Dependency Resolution in Npm v3 by city41 on Thursday December 31, 2015 @05:35PM (#10820100)
>> This is different from Apple with OSX and iOS how?

I'll never run "npm install" or "gem install" or what have you on iOS, Android, etc. Proprietary OSes come in all shapes and sizes, all bringing their own pros and cons to the mix. I just happen to be focusing on a very large con of Windows at the moment.

As for OSX, Redhat, Debian, etc. Sure, they're all different, of course. But generally speaking, at least when it comes to Node and npm (and as far as I know, Ruby, Clojure, Python, etc, please correct me if I'm wrong), these OSes tend to get along pretty OK. Windows, does not.

>> And for crying out loud, file separator issues? That's not even a hard one.

And yet how many times has that problem been hit over the decades? I mean heck, look at the commit message, "Another Windows path issue". And yeah, it's not even a hard one, it just gets worse from there.

I came to that issue from here (which is my project): https://github.com/city41/reagent-breakout/issues/11

So for "not even a hard one", still took me 20 minutes of digging to find out what was going on. X minutes across all developers across how long Windows has been around really adds up. For just one of Windows's differences.

Re:Flat Tree Dependency Resolution in Npm v3 by moron4hire on Thursday December 31, 2015 @06:14PM (#10820258)
I don't think you realize just how different even various Linux distros running even the same kernel can be, and I think you're giving waaay too much credit to OSX/Linux for being "alike". MAKE build scripts have notoriously been a mess for decades because of the differences between distros.

Any reasonable language has the ability to query all of the platform-specific stuff directly from the standard library. You can't even count on two Windows users having their home directories in the same place, or two Arch users having all of their config files in the same place. It's a necessity to be able to abstract all of these away even for a single operating system, which means you get it for free when moving to other operating systems.

Re:Flat Tree Dependency Resolution in Npm v3 by city41 on Thursday December 31, 2015 @07:49PM (#10820611)
I do get that. I totally understand all OSes are very different. How often those differences surface really depends on a lot of things, mostly at what level of the OS you are working in. Node modules and apps tend to stay pretty high level. But again, I still stand by my original statement that Windows specific issues crop up more than any other OS. Just take a look at the README for node-gyp: https://github.com/nodejs/node-gyp -- yup in OSX you have to get Xcode and a few other OSX specific steps to arrive at gcc and make, but compare that to the Windows section ...
Re:Flat Tree Dependency Resolution in Npm v3 by gelasio on Friday January 01, 2016 @01:01PM (#10822592)
Other projects have to do a lot of work to support OS X too. So I guess I still don't see your point. Electron, for instance, had to program an entirely different object model to represent OS X's kludgy global menu bar when every other OS has menus attached to application windows.

I can't believe your defending OS X though when Apple makes you buy a whole computer from them to use it...meanwhile I can run a 6 month trial of Windows (over and over again) on any virtual machine. Honestly, it's way more work to support OS X than Windows if you really bother to look at it.

Re:Flat Tree Dependency Resolution in Npm v3 by city41 on Friday January 01, 2016 @02:25PM (#10822971)
Apple is definitely not innocent here. They force a lot of terrible decisions too. I think ultimately though, this conversation boils down to my bias and experience versus your bias and experience.
Re:Flat Tree Dependency Resolution in Npm v3 by gelasio on Saturday January 02, 2016 @01:40PM (#10827242)
Sure, everybodys bias is painfully obvious here on HN.

But I don't think that negates the fact that to develop anything at all for OS X I have to buy a whole computer from Apple, since it's damn near impossible to get a stable OS X experience by running it in a VM or directly on non-Apple hardware. Furthermore, remotely accessing Xcode on a Mac from a non-Mac computer is really painful since the only option is VNC - the bottom of the barrel, lowest common denominator of remote screen sharing protocols.

Re:Flat Tree Dependency Resolution in Npm v3 by moron4hire on Friday January 01, 2016 @10:02AM (#10822029)
There is no reason building Windows software has to be this hard, other than the maintainer just not putting even a reasonable amount of effort into it.

When developers are hostile torwards Windows, this is the result. This doesn't do anything to Microsoft, this just hurts other developers and users.

Re:Flat Tree Dependency Resolution in Npm v3 by city41 on Friday January 01, 2016 @02:18PM (#10822941)
gyp was created by Google for building Chrome. I would guess they've put a decent amount of effort into it.
Re:Flat Tree Dependency Resolution in Npm v3 by tracker1 on Thursday December 31, 2015 @06:39PM (#10820356)
Given windows is the vast majority of desktops, and that there is more variety between different Linux distros and OSX versions than there are in the decades of Windows APIs, I think you have things a little backwards.

I've done far more dev targeting linux deployments the past few years, and much of it is far nicer on *nix than windows... but your viewpoint seems to be kind of arrogant. I haven't worked for a company that has more than 100 employees that doesn't do most development on windows, even if that isn't the target for deployment. That includes two major financial institutions, some large internet services and many other smaller companies over the years.

Re:Flat Tree Dependency Resolution in Npm v3 by city41 on Thursday December 31, 2015 @07:46PM (#10820595)
I don't mean to be arrogant, and if I am honestly it comes from ignorance. I've worked in MS shops before (I did .NET, COM, etc for nearly a decade). This whole thing blew up out of frustration at Windows specific issues cropping up more often than any other OS in environments like Node. I do think that's hard to deny. If that's arrogant, then I don't know what to say :-/
Re:Flat Tree Dependency Resolution in Npm v3 by Silhouette on Thursday December 31, 2015 @11:12PM (#10821073)
There is a real problem here, but I think you're laying the blame a little unfairly at Microsoft's doorstep. It's probably fair to say that at least until relatively recently Microsoft has gone to far greater lengths to ensure compatibility and longevity of code build on its platforms than any other organisation in the history of software development.

We used to value writing portable software as a skill, we used to value languages and libraries with robust specifications that could be used to write portable code, and portable code is also relatively future-proof code. I've worked on large projects that shipped on literally a dozen or more different platforms at any given time and were maintained for well over a decade with the significant variations in platforms that happen over that kind of time frame. Those projects built probably 95+% of the same source code for each platform, with platform-specific APIs and conventions carefully isolated.

That attitude and the related skills seem to have been much less valued in recent years, not least by the Linux community. (What, you want to build this C or C++ code with a tool chain other than GCC and friends?) If people carelessly scatter platform-specific code all over their projects, then of course they won't be easily portable, but more often than not such limitations are entirely artificial and could easily be avoided at negligible cost. In my experience, this is also true of a lot of libraries with the likes of Node and Python where native code is used in managed packages, and I think it's fair to consider that the resulting portability limitations are a potential disadvantage when choosing the language for a project.

Re:Flat Tree Dependency Resolution in Npm v3 by jameshart on Thursday December 31, 2015 @04:27PM (#10819784)
Seems to me that reasonable people could disagree over whether POSIX should be considered the be-all and end-all of OS standardization.
Re:Flat Tree Dependency Resolution in Npm v3 by tonyarkles on Friday January 01, 2016 @12:05PM (#10822379)
I wouldn't call it the be-all and end-all, but rather the bare minimum. "If you implement this API spec, there's a good chance a lot of software can successfully build"
Re:Flat Tree Dependency Resolution in Npm v3 by frik on Thursday December 31, 2015 @12:21PM (#10818527)
Microsoft initially aimed POSIX compatibility with Windows NT 3.1. There were POSIX subsystems for WinNT 3-5.1. Though, things changed and got worse.
Re:Flat Tree Dependency Resolution in Npm v3 by um_ya on Thursday December 31, 2015 @12:22PM (#10818533)
Better yet, why don't they just make a tool that fixes the windows problem, as a standalone patch. No need to change NPM, just need to fix the problem on Windows... The whole flat folder thing looks really bad.