Python ended up 'specializing' in data contexts, thanks to Numpy / Pandas, and as a result, ended up becoming the first exposure to programming than anyone doing data stuff had. That was millions of people. In that space, it had no competitors. Ruby ended up 'specializing' in web dev, because of Rails. But when Node and React came out, Ruby on Rails had to compete with Nodejs + React / MERN as a way of building a web…
Ask HN: Why did Python win?
481–490 of 856 posts
Re: Ask HN: Why did Python win?
#482Earlier quoted context omitted.
+1 for mentioning that python's original competitor was Perl. This point is forgotten some 20-30 years latter
Not just perl, but C/C++/Java as well. Ruby was a competitor to Java JSP development back in the day. And I remember when a lot of Java people jumped ship to Ruby. I moved from C++ to python over a decade ago and never looked back. Back then, the python jobs were scarce -- but based upon how I picked up the language, many of the typical C++ issues just disappeared -- and I knew it was going to become popular. One com…
Re: Ask HN: Why did Python win?
#483Earlier quoted context omitted.
I like Python, but most of the Zen has always been a meme, and not a guideline of design principles of either the language, or software written with it. Besides the one you mention, I also find the "Explicit is better than implicit" line to be against everything Python stands for. The language is chock full of implicit behavior, and strongly encourages writing implicit code. From the dynamically typed nature of the l…
It is absolutely not a meme, it's [PEP 20]( https://peps.python.org/pep-0020/ ). Just because some people don't take it seriously, it's definitely a part of the language's soul.
Re: Ask HN: Why did Python win?
#484Earlier quoted context omitted.
Not just practices, tooling. The whole typing system. Linting to check for mistakes. For the love of black.
Python's static typing still feels very very clunky and bolted on, and tooling around it was rather bad, like mypy. In general I definitely wouldn't say python tooling was good. It's improving rapidly with ruff tho, just as JavaScript when esbuild appeared.
Would mypy with pydantic be a good combination or do they overlap?
Re: Ask HN: Why did Python win?
#485Earlier quoted context omitted.
Just because there are people who still use it, doesn't make the statement that RoR was a fad less true. RoR was "the thing that everyone was using" at one point. It was that for several years. Anyone who's anyone was building stuff with Rails. Now it's probably the third option, when building websites... and a fourth option, when building APIs.
fad - an intense and widely shared enthusiasm for something, especially one that is short-lived and without basis in the object's qualities; a craze. --- I don't think Ruby is a fad. The drop off Ruby had since early 2010s is dramatic, but it stabilized around 5% of all PRs on GH in the last few years: https://madnight.github.io/githut/#/pull_requests/2023/2 It's still one of the most popular languages for web develo…
But is it? Stats on major job boards such as Indeed show a steep decline in recent years. There are consistently twice as many Django/Flask roles listed compared with Rails. Node is the most popular but Spring, ASP.Net and PHP occupy the next level below Node.
Re: Ask HN: Why did Python win?
#486Python ended up 'specializing' in data contexts, thanks to Numpy / Pandas, and as a result, ended up becoming the first exposure to programming than anyone doing data stuff had. That was millions of people. In that space, it had no competitors. Ruby ended up 'specializing' in web dev, because of Rails. But when Node and React came out, Ruby on Rails had to compete with Nodejs + React / MERN as a way of building a web…
Re: Ask HN: Why did Python win?
#487Earlier quoted context omitted.
Just because there are people who still use it, doesn't make the statement that RoR was a fad less true. RoR was "the thing that everyone was using" at one point. It was that for several years. Anyone who's anyone was building stuff with Rails. Now it's probably the third option, when building websites... and a fourth option, when building APIs.
fad - an intense and widely shared enthusiasm for something, especially one that is short-lived and without basis in the object's qualities; a craze. --- I don't think Ruby is a fad. The drop off Ruby had since early 2010s is dramatic, but it stabilized around 5% of all PRs on GH in the last few years: https://madnight.github.io/githut/#/pull_requests/2023/2 It's still one of the most popular languages for web develo…
Re: Ask HN: Why did Python win?
#488Python grew out of a myriad of applications that built on hard to replicate components, while Ruby relied only on web development which is remarkably subject to fashion. Python is very simple making it easy to learn. Thus, it became more and more popular for fields where programming is not the main task, like science. It is also very easy to extend with C. So, these fields could bolt on time-tested scientific code in…
> Python is very simple making it easy to learn. I would argue that there's little difference between them in ease of learning. I personally found Ruby easier because everything being an object with methods and no free floating functions felt more natural and easier to look up. i.e. string.length over Python len(string)
To me in general Ruby is the nicer feeling of the two, just generally more "friendly" and "human". Whether those are desirable traits of a language is up for debate but I think there could stand to be more language with such a flavor.
Re: Ask HN: Why did Python win?
#489Earlier quoted context omitted.
As much as I love to rag on things, I would go so far as to say that the big problem with Python packaging is the fact that it tries to manage C/C++ packaging and integration. If Python is only managing Python code, the issues to be solved are VASTLY simpler. Just about anything works. Once it has to deal with dynamic libraries, compiled code, plugins, build systems, etc. the combinatorial explosion just makes life s…
Python is a victim of its own success and versatility. It has become a better "glue code to solve your problem" than many other solutions and so people want to use it everywhere for everything. It gets packaged in many different ways because it gets used in many different ways for many different purposes.
Re: Ask HN: Why did Python win?
#490Earlier quoted context omitted.
I see what you mean, but I counter with Plone. It's been around for 24 years, and the annual Plone Conference is coming up in a couple months. Still, you don't see a whole lot of new Plone sites rolling out these days, and there's no Automattic-scale company with click-here-to-deploy convenience. Nothing against Plone (although I was very happy to put its foundation layer, Zope, in my rear view mirror). It's a fine p…
Plone never had anything even resembling Rails' popularity.