4 ms·
This doesn't answer your questions, but I firmly believe this is the major reason node took off in popularity. Npm let you install packages minutes after being
by Klathmon 8y ago
This doesn't answer your questions, but I firmly believe this is the major reason node took off in popularity.
Npm let you install packages minutes after being installed, and they went right into a folder right there, and they didn't conflict with any other packages on your system.
I was like you and played with python for years but never anything larger than small scripts, and every time I went to do "real" python I'd hit a wall where you were.
npm was just so easy, so simple, so fast that it won me over. And it was years before I ever setup a virtualenv, and even then I'm still at this point not entirely sure how it works and what it's doing despite having published a pip package.
- qudat 8y agoI'll echo this statement as someone who has published packages both to npm as well as pypi. There's no contest, npm is so much simpler as a maintainer. For anyone wondering why, no one should go beyond the confusing requirements.txt and setup.py parity madness. Furthermore, try uploading non-python files to pypi and explain to me why it has to be this difficult? The answer coming swiftly from npm: it doesn't.
- nahtnam 8y agoI don't think many people here will agree with you but I do. I use Javascript for almost everything I do because "It just works." Assuming you are running Node 6.0+ and NPM 4+ you'll almost never run into an issue unless you are using something that needs some native packages installed.
- btashton 8y agoBut the native library issue is what makes it hard for Python as well. A large part of conda existing is to help data science people not have to worry about compiling native libraries for numpy or whatever ML library they happen to be using, since it bundles these libraries.
- TeMPOraL 8y agoOr update packages? NPM land is the only place I really have to be wary about package versions, because otherwise, even when following 6-months old tutorials you'll end up with nothing working due to breaking changes between library versions. And there are just so many dependencies to keep track of...
- tekromancr 8y agoOn the other hand, as someone who knows a little js from the bad old days but has been doing python for over a decade, trying to get up and running with a modern js environment seems totally cray cray to me. Usually, for me, I start by installing node. Ok, so I guess I need to install npm now. No problem, I guess that's like pip. Oh, I need yarn. It's better? Ok, I guess python had the same growing pains with easy_install. Oh, looks like when I installed npm I used sudo, so now I need to fix file permissions burried somewhere in my file system. Okay, I guess. At least when I get this running things will be a little better. Oh, I need bundler? I guess that makes sense. Gotta configure a build system. Programing languages need build systems if you are creating distributable assets. Makes sense so far. Oh, I guess I should have used webpack. Okay, lessons learned. I guess since I am using ES6 features I need something called babel too. Cute name for a transpiler, btw. Oh no, I guess that 4 month old tutorial I followed that showed me how to set up babel with webpack used the old plug-in names. They are different now. Thats interesting. Gotta move fast, tho. I guess... Huh, it still isn't working. The 6 different config files all look right. Oh, wow. Turns out that the behavior is different if I wrote the config files in json vs yaml vs pure js. Guess I gotta rewrite them in pure js to get at the real shit. Okay, seems like I got all that mess sorted out. Let's add a few libraries to my packages manifest... Huh, the docker containers are taking an awful long time to build suddenly, I wonder why that -- WHY THE FUCK IS node_modules 7.5GB and contains 82000 files, aghhhhgh?!?! (I kid, I kid. But not really) I guess a lot of that is just cultural differences between js and python communities, but as someone who considers themselves a reasonably competent programmer, trying to get onboard just seems like too much. Contrast that with something like Rust, which I have also been trying to learn. Rust is positively delightful by comparison. I spent a cumulative total of 15 mins getting an environment set up. Which means I get more time to actually learn how to work with the language itself, instead of setting up tooling. Maybe it will sort itself out a little as the node community matures and settles on what the right way to do things is, but for now, it's so much work to even get started.
- btashton 8y agoThis is exactly how I feel every time I try and use some project using React or other project using "modern" JavaScript/Typescript. I have seen the impressive things people have done with this to solve real problems, but really I have found it to be super unapproachable, and I say this as someone that has picked up a fair amount of low and high level langauges. I want to like it, but I get turned away before I have written any code.
- dpe82 8y agoAlong the same line, I think this is also a big part of why Perl was so popular back in the day. CPAN was to Perl what NPM is today. It made finding and installing modules in a local user project directory dead simple which made getting started on a project frictionless. Though I have to say, CPAN was much better organized and documented...