What's with the hate for python. I've noticed some hate this irl and it's strange. Python is one of the best languages out there right now in terms of ease of use and future maintainability (with types).
First let me state that I do not hate Python, but I would suppose 2 items are on the top of the list for people that do. The first and the one that makes me dislike Python (not hate) is that Python enshrined into the language syntax that whitespace and structure count towards correctness. If it is not properly spaced according to the spec it does not work. Some people see this as an arbitrary constraint put on a developer and do not like it. Now I will give you others see it as a way to keep code readable, both arguments have their merits. Pretty much anything beyond noting how the two camps see it devolves into a holy war. Personally being a person that sees the beauty of LISP derived languages lack of syntax, I fall into the first camp and don't see the value of it for me.
I think the second issue, is it is fairly safe to say that the path from Python 2 to 3 was not well thought out and has been a disaster. A lot of people where burned by it, and it left a bad taste in a lot of peoples mouths.
That being said, Python enjoys a huge userbase so I would not worry about the hate, it's just not the language of choice for some people and that is fine.
I disagree with a lot of this. I feel these are minor minor complaints. You hear this kind of stuff for lisp too. For example, keeping track of parens is just as annoying as keeping track of indentation.
Also the migration from python 2 to 3 is actually the best migration ever. Breaking changes on a code that has a massive library around it. All code is migrated along with the libraries. I haven't heard of any migration done as successfully as python. It required movement of the language and the entire community to make it happen.
Most migrations refrain from breaking changes and instead they take the less risky route and make the language backwards compatible at the cost of being more bloated. See C++ 17 and C++ 20.
But despite this, yeah these are complaints that I've heard, but this is totally unrelated to the hate I see. Like parentheses in lisp is something to complain about but not something to hate lisp for.
The hate I believe is more egotistical than anything. One interviewer told me I could code in any language other than python because python makes things too simple. The hate is because they believe python programmers are stupider than normal programmers.
That being said my favorite language is not python. It's my least favorite language out of all the languages I know well but not a language I hate.
I've written Python for over a decade. There are two problems with Python.
First, the excellent readability leads directly into hard-to-read code structures. This might seem paradoxical but Dijkstra insisted that the same thing happened in FORTRAN, and I'm willing to defer to his instinct that there's something about the "shut up and calculate" approach that physicists have which causes a predilection for both FORTRAN and Python.
Second, Python 2 to Python 3 was horrible, and created political problems which hadn't existed before. Now, at the end of the transition, we can see how badly it was managed; Python 2 could have been retrofitted with nearly every breaking change and it would have been lower-friction. Instead, there's now millions of lines of rotting Python 2 code which will never be updated again. Curiously, this happened in the FORTRAN world too; I wasn't around for it, but FORTRAN 77 was so popular compared to future revisions and standardizations that it fractured the FORTRAN community.
>Second, Python 2 to Python 3 was horrible, and created political problems which hadn't existed before. Now, at the end of the transition, we can see how badly it was managed; Python 2 could have been retrofitted with nearly every breaking change and it would have been lower-friction.
This doesn't make any logical sense. Your saying take the breaking changes in python 3 and put it into python 2? That's just a version number. You can call it version 2.999999.8 and do all the changes in there and the outcome is identical.
No. Every breaking change must have a downstream change in every library that uses that breaking change. That's the reality of breaking changes. No way around it.
Tell me of such a migration as huge as python 2->3 that was as successful. For sure there were huge problems along the way and it took forever. However I have heard of very very few migrations in the open source world that ended up with an outcome as successful as python.
>First, the excellent readability leads directly into hard-to-read code structures.
I don't agree with this either. You refer to fortran but most programmers here haven't used it so you'll have to provide an example for readers to see your point.
I'm not going to argue Python politics with you, but suffice it to say that only a few communities have had such a bad major version upgrade experience. Here are some off the top of my head for comparison, from roughest to smoothest:
* Perl 5 to Perl 6: So disastrous that they rolled back and Perl 6 is now known as Raku
* PHP5 to PHP7: Burn my eyes out, please! But of course PHP has unique user pressures, and a monoculture helps a lot
* Python 2.4 to Python 2.7: Done in several stages, including deprecation of syntax, rolling out of new keywords, introduction of backwards-compatible objects and classes, and improvements to various semantic corner cases
* Haskell 98 to Haskell 2010: GHC dominated the ecosystem and now Haskell 98 is only known for being associated with Hugs, which knows nothing newer
* C++03 and earlier to C++11: Failed to deprecate enough stuff, but did successfully establish a permanent 3yr release cadence
* C99 to C11: Aside from the whole Microsoft deal, this was perfect; unfortunately Microsoft's platforms are common in the wild
Now consider how many Python 3 features ended up backported to Python 2 [0] and how divisive the upgrade needed to be in the end.
On readability, you'll just have to trust me that when Python gets to millions of lines of code per application, the organization of modules into packages becomes obligatory; the module-to-module barrier isn't expressive enough to support all of the readable syntax that people want to use for composing objects. If you want a FORTRAN example, look at Cephes [1], a C library partially ported from FORTRAN. The readability is terrible, the factoring is terrible, and it cannot be improved because FORTRAN lacked the abstractive power necessary for higher-order factoring, and so does C. Compare and contrast with Numpy [2], a popular numeric library for Python which is implemented in (punchline!) FORTRAN and C.
Did you by any chance observe any of the folks involved officially saying that deprecating things was one of the goals? I thought keeping working code working has always been of the C++'s official goals.
There's a lot to complain about for python. But I see genuine hate. People, groups and companies who literally refuse to use it.
I had an interviewer tell me that I couldn't code up the solution in python. I think it might be because python is so easy that people look down on it.
There's a certain cultural subset which tries to bolster their self-assessed superiority by rejecting things which are popular. This is especially common for people coming of a certain academic bent who are constantly playing one-upmanship games desperately trying to be the smartest person in the room.
Python annoys those people because it's both relatively easy to get started with and far, far more successful than whatever their current favorite language is, and this is portrayed as people not getting it rather than having a more insightful discussion about whether other people might reasonably make decisions based on different needs, background, and resources rather than stupidity.
I think the second issue, is it is fairly safe to say that the path from Python 2 to 3 was not well thought out and has been a disaster. A lot of people where burned by it, and it left a bad taste in a lot of peoples mouths.
That being said, Python enjoys a huge userbase so I would not worry about the hate, it's just not the language of choice for some people and that is fine.