Compare source code

Tim Harig usernet at
Tue Nov 2 20:26:56 CET 2010

On 2010-11-02, Seebs <usenet-nospam at> wrote:
> On 2010-11-02, Steven D'Aprano <steve at> wrote:
>> If your 
>> editor changes spaces to tabs, or visa versa, without being told to do so 
>> (either by an explicit command or an obvious setting), then your editor 
>> is broken.
> Yes.  But that's the thing -- I *want* that behavior for every other tool,
> file format, or other thing I work with.

I agree with Seebs, Python is the only language I know that promotes
the use of spaces over tabs; and there are equally picky syntaxs (ie,
Makefiles) that mandate the use of tabs.  I personally prefer tabs as
it lets *me* decide how far the apparent indentations are in the code.
You may like four spaces; but, I agree with Linus Torvalds that eight
spaces is much clearer.  The beautiful thing about tabs is that we can
both set our tab stops to match our own viewing preferences.

>> If you are stuck with broken mail servers and broken editors and broken 
>> tools because of political reasons, then you have my sympathy. But stop 
>> insisting that everybody has to carry the overhead of your work-arounds 
>> for your broken tools.
> I have made no such insistance.  I have not said Python should change.  I
> have not said other people should want what I want.  I'm not the one telling
> other people that editors they've used happily for twenty years without
> any problems are clearly wrong.

Indeed, a simple script is enough to identify how levels are indented and
convert the present indenting to whatever is your preference.

> There are reasons for it to be this way, and I don't object to the
> existence of people who prefer that side of the tradeoff.  I do dislike
> it when people smugly tell me off for having different preferences.

This is Python's most noticable blemish outside of the community.
Everybody knows that Python is the language that forces you to use a
particular style of formatting; and, that is a turn-off for many people.
It is a big mistake that whenever the issue arises, the community
effectively attacks anybody who might have disagreements with the tradeoffs
made for the Python language.  This tends to set people on the defensive
and gives them a bad taste about the language as a whole.

It would be much better if the community would simply acknowledge that
this is a tradeoff the the language has made and one which is often
misunderstood by many first time Python programmers.  Then it is possible
transition to Python's strengths.  Don't simply ignore that there *are*
potential downfalls to this approach.

More information about the Python-list mailing list