3 ms·
This is seriously one of the dumbest things I've read in a while. The points the author makes about version incompatibility were already very weak in 2018, whe
by blacklight 4y ago
This is seriously one of the dumbest things I've read in a while.
The points the author makes about version incompatibility were already very weak in 2018, when the article was written and Python 2 had already been declared deprecated. They don't make any sense today.
The problem about incompatibility across minor version is nonsense. Yes, some new features introduced in a minor version are often not back-compatible with previous minor versions (like the walrus operator in 3.8, or typing annotations on variable declaration in 3.6), but the previously written code is ALWAYS forward-compatible to newer minor versions.
The complaint about the syntas being unreadable is also bogus. "You end up with your editor wrapping the long lines!" - well, just use parentheses to wrap complex expressions and break them down on multiple lines, like I do in EVERY programming language.
"Finding a list of what can be imported is not intuitive and people end up grepping the codebase" - grepping header files in /usr/include is exactly what I've been doing for years in C/C++. In Python you have sys.path telling you which paths are searched for modules - and, in most of the cases, if you used a virtual environment or system-installed modules, all the modules will be in the same folder anyway.
The complaint about 3rd-party libraries having inconsistent names (with Py at the beginning or end of the name) is also laughable nonsense. Take a look at the 3rd-party libraries built for Ruby, JS or PHP, and tell me where you find name consistency.
The complain about passing objects by reference is also nonsense. Java does it as well: if you pass a primitive value, then you pass it by value. If you pass an object, then you're passing a memory location by reference. It may seem unintuitive at first, but once you get used to it you really appreciate it, because you don't have to create a lots of copies of a value for different function calls unless you have to.
To be clear, I also criticize many of Python's design choices. Starting with its functional features, which are either ugly afterthoughts or they don't exist at all. I hate the idea of using list comprehension for everything, or having map/filter/reduce that either support one-liner lambda with an ugly syntax, or some cryptic getters defined in the operator module. And I was expecting to find this type of criticism in this article. Not the shallow rant of someone who has barely touched Python.