3 ms·
I've been downvoted quite a bit for snarkily dissing on python. I am not a fan. But... to give credit where credit is due... python has done a number of thing
by retrocryptid 3y ago
I've been downvoted quite a bit for snarkily dissing on python. I am not a fan.
But... to give credit where credit is due... python has done a number of things right.
Most people I know like python because the syntax hasn't changed that much in the last 5 years or so, so they don't remember the horrible times in 1.x and 2.x where syntax, semantics and tool changes between minor revs caused headaches.
Good on you, python 3.x developers. You have done a good job of not repeating some of the worst problems from an earlier era.
I think the reason people tolerate python (and even like it) is there's a lot more opportunities to write small snippets of code. AWS Lambdas come to mind, but there are plenty of other opportunities.
Instead of having to whip up applications that do EVERYTHING, it's much more common for your code to run inside an established framework (thinking of django) where an existing code blobs already exist to access other infrastructure (databases, caches, event streams, etc.)
An important aspect of python's popularity is the context in which python code is executed. You don't write all of an app w/ python, you pick a framework that works for your uses and just use that. Or at least, you have more of an opportunity to do that with modern languages it seems.
Also, there's a large and often useful "extended standard library" of modules. As a C fan, I have to admit I'm jealous.
And as much as I feel violated by python 2.x, it's nice to see that in the 3.x world you can frequently get a version clean dependency closure (i.e.- your dependencies and their dependencies and their dependencies all work well on a specific version of the language.)
I would remind people, however, that "python" is not a language. It is a family of languages with related syntax and semantics. There are still problems getting code from different versions of python to work together, but it is MUCH less of a problem in 3.x than it was in 2.x. (Thankfully most people reading this post weren't out of diapers when 1.6 was released.)
I have "issues" with most pythons' syntax and semantics, but they're probably not problems for most people, so I'll keep them to myself.
I recently realized I wrote my first Lisp program 50 years ago and much prefer "extension by composition", but we all do what we feel most comfortable with.
I've just had to maintain other people's crappy python 1.6 code, porting it to 2.3, 2.5, 2.7, 3.4, 3.6 and 3.8. I dislike having to do this. But if you're writing small snippets of code, offload your code to a different team for maintenance or change jobs every year, it's a perfectly fine language.