Ask HN: Is Python losing its beauty?

10 points by scared2 ↗ HN
Python is sensationally known for its simple and exquisite syntax. But recently it is being bloated, on each version you can see it stuffed with features just for sake of adding a feature.

this assignment operator ":= " which was recently added is a typical example.

Do you think it is necessary to bloat python with too many features?

11 comments

[ 3.2 ms ] story [ 30.2 ms ] thread
Beauty is in the eye of the beholder, clearly. I think it's foul, midnight is False, one minute past is True, a 1-tuple is written (2,) and you join strings with

  '/'.join(['a', 'b'])
  
and don't get me started on classes ...
You may not think it's necessary but languages evolve and tend to add features. Unfortunately it' not practical to remove features from a mature language. This might look like bloat.

I happily use a subset of Python including a smattering of new features when they add value to the task at hand. This set of features has evolved over time and makes me more productive and allows me to write clean simple code.

If you don't like a new feature just don't use it. There is no rule that says you should use any feature which doesn't help you write great code.

I agree that you can write with just a subset of the language. But the problem arrises when you have to read somebody else's code.

If there are too many features as opposed to "one and only one way to do it" you will end up with a source code that is unintelligible between two developers.

Imagine it has M+N features that are mutually replaceable. The problem arises when you have a very good programmer that writes a complete program using the M features, and when you get programmer b who is also good but hasn't heard of the M features.

True. But it doesn't take 'too many language features' to make very different code. Two designers at my startup years ago approached our database object model from completely orthogonal directions.

The programmers were both named Robert. So we called the approaches "Robjects" and "Bobjects".

yes. hate those print() brackets with a furious passion. That put me right off and steered clear of the language.
making it uniform with function invocation always seemed more elegant and sane
The walrus operator is a very extreme example - the controversy around it directly disrupted the entire governance system of Python for a while. On the other hand not all new features detract from the simplicity of the language - f-strings are a wonderful example of this.
No, I hate the new features. Python already has enough syntax to describe almost any coding pattern. If it was up to me I would instead remove as much extraneous syntax as possible. Axe the type declarations, function decorators, f-strings, matrix multiplication operator and so on.
I don't think so.

There's things that are weird, but you can just not use those.

I find static typing useful in certain scenarios, for example.

Having the flexibility to employ certain techniques when needed is very handy.

This reminds me of a domestic quarrrel when we were searching for a dishwasher. She wanted a stainless steel automatic dishwasher with four speeds and selectble wash cycles. She also requested the fully integrated digital touch control panel with fuzzy logic modulated jets and multiple racks with fold down tines.

I felt it would be sacrilegious to waste money on these extras — just to clean the dinnerware. Why do you think God gave us tounges? She is now living with an applance salesman.