February 20, 2021, the 30th anniversary of Python, finds the programming language at the top of its game but not without challenges. "I do believe that Python just doesn't have the right priorities these days," said Armin Ronacher, director of engineering at software monitoring biz Sentry and creator of Flask, the popular Python web app framework, in an email interview with The Register. Ronacher, a prolific Python contributor, remains a fan of the language. He credits Python's success to being both easy to learn and having an implementation that was easy to hack. And in its early years, Python didn't have a lot of competitors with those same characteristics, he said
[...] The shortcomings of Python's software packaging tools – the software used to set up Python environments and to download, install, and manage libraries – have been an issue for years. It was bad enough that cartoonist Randall Munroe, on April 30, 2018, penned an xkcd comic on the subject.
Things have improved somewhat since then. In 2019, the Python Software Foundation awarded the Packaging Working Group $407,000, courtesy of Mozilla and the Chan Zuckerberg Initiative, to renovate the pip package management tool in 2020.[...] For the Python community, bringing new people in so others can step back or delegate may help mitigate that sense of siege. Jodlowska credits efforts by Python core developers to keep the community vital. "A lot of the current core developers, for example, on their own time mentor others who are interested in becoming core developers," she said. "And there's definitely a steady stream of new incomers that way."
[...] Thirty years on, Python deserves recognition for what it has accomplished but it can't rest on its laurels. Rival programming languages like Julia and R in data science, and Go in cloud-native applications, have been turning heads. And the need for greater memory safety, to reduce security risks, has helped push TypeScript and Rust into the spotlight. Uneasy lies the head that wears a crown.
What's your take on this ?
(Score: 1, Funny) by Anonymous Coward on Sunday February 21 2021, @11:58AM (8 children)
Fnord666 must have imported a faulty date module.
(Score: 3, Touché) by RamiK on Sunday February 21 2021, @12:35PM
It's timestamped 11:05AM so maybe it was still the 20th somewhere around that time...
compiling...
(Score: 0, Flamebait) by Anonymous Coward on Sunday February 21 2021, @01:46PM (6 children)
(Score: 3, Insightful) by Subsentient on Sunday February 21 2021, @02:29PM (4 children)
Tab master race. Less bytes, less chance of clicking in between the indentation by accident, and you can set the display width to whatever you want.
Python's style guide prefers that I use spaces. Like that's gonna happen. Every language has a style guide, and I ignore all of them.
"It is no measure of health to be well adjusted to a profoundly sick society." -Jiddu Krishnamurti
(Score: 2, Insightful) by Anonymous Coward on Sunday February 21 2021, @03:11PM (3 children)
When it comes with a code of conduct … well, you can figure out the rest.
A tab is a tab is a tab. Accept no substitutes. Languages that want you to indent with a few spaces instead of a ull tab are compensating for being overly verbose, to try to fit overly long statements on the screen without excesssideways scrolling. Java is the canonical example. I
(Score: 0) by Anonymous Coward on Sunday February 21 2021, @07:32PM
A tab is 8 spaces motherfucker and anyone who disagrees is a fucking DIRTBAG traitor to the God of programming, Steve Ballmer.
(Score: 1, Interesting) by Anonymous Coward on Sunday February 21 2021, @08:19PM (1 child)
Having a style guide isn't really much of an issue. It's the fact that Python feels the need to enforce style which causes the problems. For those of us with learning disorders, semantic whitespace is particularly problematic. For everybody else, it limits the choices you get to make in service of improved readability. You shouldn't have to engage in kludges in order to split a line of code over multiple lines in order to make it easier to read or modify.
Python is a fine enough language after you've already learned to program other languages, but it utterly fails as a language for beginners due to the incompetent design decisions that were made. White space should be purely a matter of keeping elements separate and for the sake of readability. Dynamic typing is evil, if you're going to have types they should be static as God intended.
(Score: 1) by Zappy on Monday February 22 2021, @01:22PM
Python pretty much has only one type. Pointer to an object.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @04:02PM
Significant whitespace: something everyone learned was unnecessary and a recipe for errors from experience since the 1970s. (Well, the author of "make" was ignorant, but realized his mistake only after he had an installed user base and couldn't change it.)
Guido has shown a pattern: he makes Python syntax different from all other languages just for the sake of being different so he can claim to have "innovated." It's a sign of immaturity and egotism.
(Score: 0) by Anonymous Coward on Sunday February 21 2021, @12:34PM (3 children)
Don't know how it happened, but the abortion failed and we seems to be stuck with a seriously retarded programming language that every research under/graduate use to try expressing their ideas into.
(Score: 0) by Anonymous Coward on Sunday February 21 2021, @01:27PM
try:
witty rejoinder defending Python
except:
make fun of Rust
(Score: 0) by Anonymous Coward on Sunday February 21 2021, @08:21PM
It's mostly because many colleges are using it as an intro language. I have no idea why, it's a complete and utter failure as a starter language. It's even worse than the JavaScript that they replaced with this abomination. You can definitely do serious work with Python, but the features that people cite as making it easy for beginners are what make it a particularly unpleasant for beginners. Semantic white space, dynamic typing and the lack of informative error messages in particular are not features that I would associate with being easy for beginners.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @12:31AM
The article is just plain weird. In what universe is Rust serious competition for anything, including BASIC?
(Score: 5, Funny) by bart9h on Sunday February 21 2021, @01:02PM (5 children)
{ }
(Score: 2, Funny) by Anonymous Coward on Sunday February 21 2021, @03:51PM
:(
(Score: 3, Funny) by istartedi on Sunday February 21 2021, @07:03PM (1 child)
A large burlap sack arrives in Python land. The hungry desperate people tear it open, expecting wheat or beans. Instead, out comes ((())(((())))((())). Befuddled, they check the print on the bag: A GIFT FROM THE PEOPLE OF LISP.
Appended to the end of comments you post. Max: 120 chars.
(Score: 3, Funny) by hendrikboom on Sunday February 21 2021, @09:44PM
And it contains an unbalanced parenthesis. A Trojan horse, maybe?
(Score: 0) by Anonymous Coward on Sunday February 21 2021, @07:34PM (1 child)
Fuck your brackets. 2 + (2=4) any way you write it.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @04:30PM
Syntax error.
(Score: -1, Spam) by Anonymous Coward on Sunday February 21 2021, @02:20PM
https://archive.org/download/TerryADavis_TempleOS_Archive/videos/2017/2017-07-12T04:47:05+00:00%20-%2008JewishPig.MP4 [archive.org]
Terry A. Davis in one of his greatest videos ever!
(Score: 3, Interesting) by inertnet on Sunday February 21 2021, @02:40PM (12 children)
Randal Munroe explained exactly why I'm avoiding Python where I can. It seems that over time you can only keep half the stuff that relies on Python working, because of that ugly versioning mess. Be careful when you're required to update Python for some application, because a lot of others might stop working as a result. I'm about to install my system again from the ground up because of this.
(Score: 0) by Anonymous Coward on Sunday February 21 2021, @03:19PM
Having to rewrite things because of a language upgrade is a shitty form of job security, and gives you a reputation for writing brittle code in the long run, which is bad for long-term job security.
(Score: 0) by Anonymous Coward on Sunday February 21 2021, @04:03PM (6 children)
> Be careful when you're required to update Python for some application, because a lot of others might stop working as a result.
Using python virtual environments prevents these issues.
(Score: 0) by Anonymous Coward on Sunday February 21 2021, @04:10PM
In other words, backwards compatibility is crap and you need to take extraordinary measures to compensate. The best one would be to stop incurring repeated problems and technical debt be switching source language. Because it’s going to happen again since backwater compatibility is not a priority.
(Score: 1, Touché) by Anonymous Coward on Sunday February 21 2021, @04:42PM
(Score: 3, Interesting) by inertnet on Sunday February 21 2021, @05:04PM (1 child)
On the contrary, in fact I'm assuming that virtual environments that I had to set up years ago when I was assessing if I wanted to use Python for programming, are now preventing proper operation of updates of regular software. Even the update tools have stopped working, so I need to manually 'sudo apt upgrade' whenever the 'updated software is available' popup appears. The long story:
Back in December I had a hunch that Bitcoin was going to rise in value substantially. So I bought some bitcoins into a wallet that I hadn't used for a couple of years. When I tried to open my "Electrum Bitcoin Wallet", it complained that I had to update it first, so I did because otherwise I wouldn't be able to access my newly bought bitcoins. In that process I got a complaint that I needed to update Python to 3.7 (if I remember correctly). I don't remember exactly, but after updating I probably needed to tweak some settings before I finally got to use my bitcoin wallet. What happened was that most of the rest of my system appeared to be crippled. Since then I have managed to get the most important ones working again, but I need to do a complete fresh Linux install to get everything the way I like. After that I'll never ever mess with Python again.
My bitcoins have almost doubled in value in two months though, so some good still came out of it. I only wish I had more money to invest than just my Christmas bonus.
(Score: 0) by Anonymous Coward on Tuesday February 23 2021, @08:49AM
it's not an investment.
it's people heating up the atmosphere for no reason.
you idiots are well on your way to overtake religions when it comes to wasting resources for fanciful stories told by a few conmen.
(Score: 3, Insightful) by toddestan on Sunday February 21 2021, @08:52PM (1 child)
Python virtual environments is just a hack to deal with an issue that ideally wouldn't exist in the first place.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @02:35AM
Correct, the real solution is Docker containers, now your versioning is solid.
(Score: 1, Insightful) by Anonymous Coward on Sunday February 21 2021, @05:04PM
Any language that does that isn't worth using to build anything with lots of lines of code, unless you're paid per line of code and don't mind endless pointless migration where most of the time and resources is NOT spent fixing "real problems" but instead to fix the problem of using a language that has no commitment to backward compatibility.
(Score: 1, Informative) by Anonymous Coward on Monday February 22 2021, @04:16PM (2 children)
Python, the only language where a point version increment to the language breaks all your scripts.
No respect for working code. Python is beta code... forever.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @10:57PM (1 child)
> Python, the only language where a point version increment to the language breaks all your scripts.
Nah, this brain damage isn't just python.
Java is arguably worse. Used to have to run three versions of the JVM on a single server to run a single "enterprise" application at work for a while. Java wins the dumpster fire award here.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @11:36PM
That has not been my experience at all, but if you say so, I assume it was for your code.
At least with the language itself (not libraries), the syntax changes have been remarkably backwards compatible over the decades. That sort of thing is highly valued in Java, and not all in Python.
(Score: 1, Disagree) by bzipitidoo on Sunday February 21 2021, @04:20PM (26 children)
Every time Python is discussed, we get the people who hate it for its use of spaces. This is a misdiagnosis! The only reason it's done that way is because ASCII is terrible for markup. If ASCII had devoted 2 of the two dozen useless control characters to indentation, basically make them into invisible parens, this entire criticism of Python would be moot.
(Score: 1, Insightful) by Anonymous Coward on Sunday February 21 2021, @05:30PM (6 children)
Are you being intentionally thick? ASCII devotes exactly one character - 0x09 -TAB - to indenting. Get an old typewriter and you can manually set the tab stops )except on the cheap ones where it’s fixed at every 8 spaces).
The white space character - 0x20 - SPACE - is strictly a word separator , not a tabulator.
Same with the other control characters.
Python space-as-tab is brain dead.
(Score: 1, Disagree) by bzipitidoo on Sunday February 21 2021, @07:01PM (1 child)
No. TAB was way overloaded. It was supposed to align columns of tables and indent, and ended up doing neither well. TAB is a mess.
One thing about ASCII that is largely forgotten today is that the exact meaning of many of the control characters was purposely left vague, because the committee wasn't any too sure what should be in the character set. Well, now, I venture to say we do have a better idea what should be in there: structure. More structure.
Yes, they were heavily influenced by typewriters. The way typewriters handle position is limited and rudimentary, thanks largely to the mechanical limitations of the physical devices. There's little reason to hobble ourselves by continuing to limit computers to what typewriters can do.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @04:36PM
Not typewriters. Teletype machines which came from typewriters. They were electromechanical information transmission devices.
(Score: 0) by Anonymous Coward on Sunday February 21 2021, @07:33PM (2 children)
How do I manually set tabstops on my screen? I want the first stop at 6, the second at 10, and repeating stops every 4 spaces thereafter.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @12:36AM
(Score: 0) by Anonymous Coward on Monday February 22 2021, @03:00AM
Provide the list to "tabs" and it will adjust your terminal accordingly.
(Score: 3, Interesting) by darkfeline on Sunday February 21 2021, @09:23PM
Tabulation is not indentation. The proper use of the tab character is in the middle of lines, to align columns of a table, not at the beginning of a line. That's why tab stops, plural, exist.
Also, Python does allow tabs as indentation. Notably, the creator of Makefiles, one of the few file formats that actually require tabs for indentation, laments the mistake he made.
Join the SDF Public Access UNIX System today!
(Score: 0) by Anonymous Coward on Sunday February 21 2021, @05:33PM (2 children)
Also, those old content characters had very specific uses, such as FIELD SEPARATOR, RECORD SEPARATOR, GROUP SEPARATOR, etc. All handy for both storing and transmission data in non-fixed-size record formats.
(Score: 2) by bzipitidoo on Sunday February 21 2021, @07:04PM
Yes, I think the separators are some of the best largely unused control characters in ASCII.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @04:34PM
Those would only have meaning for transmitting the equivalent of CSV data but with the added advantage of not being able to see what is being sent without using a binary editor since the separator characters are all invisible. There's a reason those characters don't get used ever.
(Score: 2) by pe1rxq on Sunday February 21 2021, @05:37PM (11 children)
Nope, your still stuck in 'indentation is part of the language' land.
Don't try to blame it on ASCII, everybody knows the language design itself is the result of a special kind of brain damage
(Score: 2, Disagree) by bzipitidoo on Sunday February 21 2021, @06:50PM (10 children)
Do you believe in Proper Indentation, even a little bit? How about using multiple lines and the C++ comment notation, "//"? Or are all your C programs one liners, because you can jam 100k of source on one line if you really really want to. The compiler shouldn't care about that in the least.
Position is one of the major ways to indicate structure. The other is the use of symbols such as brackets. We use positioning for a lot more things than structured programming. It works. It's good. It's a problem that ASCII is so severely limited and clumsy in what positioning it can do. Leading spaces are a terrible, terrible way to position text, but it's all ASCII has.
(Score: 0) by Anonymous Coward on Sunday February 21 2021, @08:30PM (8 children)
Indentation shouldn't be a part of the language at all, not even a little bit. The indentation is there for humans so that we can more easily see the grouping of things. The computer shouldn't need that at all as the limit of what's visible on screen isn't relevant. That's one of the reasons that many languages require a specific character for the end of the line, it allows you to spread code over multiple lines on your screen, or not, as you see fit.
You do need some method of separating different elements out, but there's no inherent reason why that needs to be whitespace. It's just that a space is the least likely to conflict with things you're writing. Sure you can write things like $var1$var2$var3 in some languages and the language will figure out that when you hit that next $ or " " that we're on to another variable, but that's not terribly easy to read and if you accidentally leave out the $ it's hard to say what you'll get at the end.
(Score: 2) by hendrikboom on Sunday February 21 2021, @09:51PM (6 children)
It is very helpful when you are debugging to have the computer use the same signals to determine program structure as you do.
(Score: 1, Touché) by Anonymous Coward on Monday February 22 2021, @12:37AM
I've worked with "programmers" that get confused if brackets are not on their own line and others that can't cope with brackets that aren't on the same line as the function name. Others get confused if brackets and such don't line up. I think you have to get past formatting because the formatting of code can be misleading.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @12:44AM (4 children)
(Score: 0) by Anonymous Coward on Monday February 22 2021, @02:46AM
Best to ignore the formatting of code and stick to understanding...er...the actual code itself. Same can be said of most of the comments that I see in source files.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @02:11PM (1 child)
cond = true;
while ( ! cond )
do_something();
cond = false;
(Score: 0) by Anonymous Coward on Monday February 22 2021, @04:54PM
Your example depends on the language. Some languages allow only blocks for loops--no single statements allowed. Your example could never happen in those languages. For other language that do allow single statements in loops as well as marked blocks, company policy was to always use marked blocks, no exceptions ever, so we avoid the problem.
The problem is that Python blocks don't have marker for "end block", only "begin block" (the colon char). When you try to change the scope of a block in Python by wrapping it in another loop, you've got to be VERY careful to properly indent all existing code below the new loop correctly. Since there is no "end loop" marker, it is very easy to accidentally leave the last block statement as-is without indenting it another level as required. Your loop is now missing that statement which will now incorrectly execute once after your loop has ended. There is no way to visually catch this mistake after you make it because there is no "end block" visual marker. No other programming language has this hard to catch problem.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @04:14PM
Guess you've never passed your code through a style guide enforcer at work.
(Score: 0) by Anonymous Coward on Saturday February 27 2021, @05:30PM
Look, it‘s better if the human and the computer use the same clues for determining AST structure. Otherwise something like the openssl apple disaster happens (where they edited an „if“ statement body to add a statement, but forgot to add block brackets around the now two statement).
Gcc and other compilers added warnings if the indentation is wrong since then, so indentation is now part of C, too.
As for your other comment, I’ve worked with Microsoft Basic on C64 where indeed you don‘t need to separate tokens by whitespace (and people generally didn‘t), and it was horrible to read. We‘ve progressed since then.
Now, let‘s progress again.
As for hard wrapping source code lines before the statement is finished, we shouldn‘t do that either. What use is it? Soft wrappng is just fine. No one is printing source code on their 80 column matrix printer anymore either.
(Score: 0) by Anonymous Coward on Sunday February 21 2021, @10:06PM
I have never seen a c compiler that requires a specific indentation. C programs written decades ago still compile on newer versions.
Indentation is a sop to humans, period. You’re probably one of those retardant who think writing pho code and putting every parameter on a new line spaced all the hell to the right to line up with the opening parentheses is good style. “Because it lines up.” Gets really interesting when people use different mixes of tabs and spaces in their editors.
Or that Java is great because everythingIsSoFuckingVerboseThatYouNeedToAvoudTabs and you still have to sidescroll.
Would have been better to just name python3 as something else, same as Perl and parrot (which was supposed to be perl6, but died).
(Score: 3, Insightful) by engblom on Sunday February 21 2021, @10:17PM (3 children)
ASCII predates Python by far and the creator knew that ASCII did not have any such character. Still he went this stupid route. All other languages use also ASCII but their creators were smart enough to use characters like {} to tell were a file should be indented. Any capable editor will take care of it from there.
Now if we have something written in Python and we copy and paste code around we have to work through it all to reindent it. With any other language I would just tell the editor to reindent the whole file instead of doing it manually.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @12:51AM (2 children)
Plenty of c and c++ code that doesn’t need braces because there’s only one statement in the code that follows. Braces become visual noise. And you can often not even stuff the code following the closing parentheses on the same line.
It’s foolish to use excessive lines and braces for simple if() and ?: statements that can be collapsed on a single line.
(Score: 2) by engblom on Monday February 22 2021, @12:24PM
I never claimed anything else. If there would just be single statements for conditionals, loops etc even a messy Python file could be automatically indented by an editor. Braces (or "begin" and "end" or "if" and "fi" etc, depending on, language) is there to denote a multi-line block. Python got nothing for this, except for the number of spaces in front of a line. This makes copy and pasting inside of a Python file a nightmare.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @04:56PM
Those two chars { and } are just SOOOO much visual noise, I just can't mentally deal.
(Score: 0) by Anonymous Coward on Sunday February 21 2021, @07:08PM
"Thirty years on, Python deserves recognition for what it has accomplished but it can't rest on its laurels. Rival programming languages like Julia and R in data science, and Go in cloud-native applications, have been turning heads. And the need for greater memory safety, to reduce security risks, has helped push TypeScript and Rust into the spotlight. Uneasy lies the head that wears a crown."
or Nim which is GC'd, but runs at the speed of manual memory management, and has clean python-like syntax.
(Score: 3, Interesting) by Rich on Sunday February 21 2021, @09:58PM (2 children)
Works from shell with a #!
Less brain dead than sh
More library than awk
Better readable than perl
That got it into the door, and from then on, it was good enough. Late-comers, like ruby or lua couldn't displace it. Well, lua does, but only where embedded scripting must be compact. A fraction of the "market".
I use Python as digital duck-tape, because it comes with every UNIX-like install, but I couldn't tell you where any of the versions between 2.0 and HEAD differ. I know some "print" commands stopped working. If there was something faster, more stable (wrt changes), with type checking, and universally available, I'd use that instead. Maybe Apple dropping the install opens a window of opportunity for something new.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @12:54AM (1 child)
(Score: 1, Informative) by Anonymous Coward on Monday February 22 2021, @04:11PM
Mr. Pedant, the name of this product was "duck tape" because the tape was originally made of cotton "duck" which is a type of fabric. Some ignoramus didn't know that and starting to incorrectly call it "duct tape." Then, from repetition and usage in duct work, everyone thought that was its real name. It is not made of cotton fabric anymore, but vinyl, so neither "duck tape" nor "duct tape" is descriptive. Maybe we should just start calling it "kludge tape."
(Score: 0) by Anonymous Coward on Sunday February 21 2021, @11:11PM (1 child)
By being 100 times slower than C, this language has needlessly impacted our environment. We had to buy more computers, throw away old computers sooner, run more cores at once, build bigger batteries, install more cooling in datacenters, and on and on. Python keeps hurting us.
It's probably running on spacecraft even, making it safe from rising seawater.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @12:58AM
100 times slower than c? More like 1,000 times, which is why they write various libraries in c - you want results before the next climate disaster power failure requires you to start another run from the beginning.
(Score: 2) by Rich on Monday February 22 2021, @09:27AM (1 child)
"Duct tape (also called duck tape, from the material it was originally made of [(cotton duck)]) ..."
""Duck tape" is recorded in the Oxford English Dictionary as having been in use since 1899;[2] "duct tape" (described conservatively as "perhaps an alteration of earlier duck tape") since 1965.[3]"
(Wiki)
(Score: 2) by Rich on Monday February 22 2021, @09:45AM
Eh. Wrong reply button. The above message belongs into the "At the right time..." thread, where I referred to Python as "digital duck tape". Sorry.
The reply delay gave me the chance to investigate the etymology: An online source (the "gaffatape.de" shop, which some might dismiss as not credible, because they are convinced it is "gaffer") state that the "duck" may come from the dutch word "doek" for cloth (related to German "tuch"), an English "duck" is known "eent" in the Netherlands. To confuse things further, there is an actual brand with a duck (ducktape.eu).
(Score: 2) by Phoenix666 on Monday February 22 2021, @03:49PM
No 'happy birthday' from me, Python. I'm still trying to untangle your mess after performing an innocent upgrade on my system last week.
Washington DC delenda est.
(Score: 0) by Anonymous Coward on Monday February 22 2021, @04:18PM
Same typical basic problems (human and technical) as the others.
(Score: 2) by DannyB on Monday February 22 2021, @06:38PM
Inside every dynamic language is a type safe statically compiled language struggling to get out.
Young people won't believe you if you say you're older than Google. (born before 1998-09-03)