Path: csiph.com!usenet.pasdenom.info!weretis.net!feeder1.news.weretis.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.freenet.ag!news2.euro.net!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.002 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; '(python': 0.07; 'python3': 0.07; 'stops': 0.07; 'default.': 0.09; 'mixed': 0.09; 'option,': 0.09; 'spaces': 0.09; 'python': 0.11; '"default': 0.16; '*always*': 0.16; '*any*': 0.16; 'all?': 0.16; 'columns': 0.16; 'configuring': 0.16; 'formatted': 0.16; 'from:addr:r.koebler': 0.16; 'from:name:roland koebler': 0.16; 'preserve': 0.16; 'programmers.': 0.16; 'received:78.47': 0.16; 'settings,': 0.16; 'tab': 0.16; 'tabs': 0.16; 'size,': 0.16; 'code.': 0.18; 'dependent': 0.19; 'things.': 0.19; 'meant': 0.20; 'settings': 0.22; 'source': 0.25; 'header:In-Reply-To:1': 0.27; 'said,': 0.30; '(which': 0.31; 'code': 0.31; "skip:' 10": 0.31; 'idea,': 0.31; 'indentation': 0.31; 'option.': 0.31; 'subject:all': 0.32; 'option': 0.32; 'quite': 0.32; 'text': 0.33; 'style': 0.33; 'skip:d 20': 0.34; 'common': 0.35; 'tool': 0.35; 'convert': 0.35; 'editor': 0.35; 'but': 0.35; 'add': 0.35; 'there': 0.35; 'charset :us-ascii': 0.36; 'hi,': 0.36; 'should': 0.36; 'to:addr:python- list': 0.38; 'previous': 0.38; 'expect': 0.39; 'does': 0.39; 'bad': 0.39; 'to:addr:python.org': 0.39; 'how': 0.40; 'even': 0.60; 'simply': 0.61; 'content-disposition:inline': 0.62; 'such': 0.63; 'different': 0.65; 'between': 0.67; 'default': 0.69; 'warning.': 0.84; 'subject:you': 0.87; 'avoided.': 0.91; 'yours.': 0.93 Date: Mon, 8 Apr 2013 00:52:58 +0200 From: Roland Koebler To: python-list@python.org Subject: Re: I hate you all References: <906d8c05-99dc-4209-854c-7988ca7c78e3@googlegroups.com> <95b2bc1c-57a2-48c9-85ea-cf1004c9e26c@googlegroups.com> <515fad75$0$32109$14726298@news.sunsite.dk> <515fc72c$0$32106$14726298@news.sunsite.dk> <51602fb8$0$32114$14726298@news.sunsite.dk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <51602fb8$0$32114$14726298@news.sunsite.dk> X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 46 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1365375488 news.xs4all.nl 6936 [2001:888:2000:d::a6]:38289 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:43030 Hi, > Well all previous (python 2) code is meant to work for a tab size of > 8. yes, but even in Python 2, mixing spaces and tabs is considered bad style and should be avoided. And code-checkers like pylint (which I can recommend to everyone) create a warning. > You may call this "categorically wrong", but it has been there a > long while, is is still in use, and it sticks to the default. As I said, mixing tabs and spaces for indentation was *always* a bad idea, and is discouraged also in Python 2. > Spaces-only can achieve compatibility between different people > settings for formatted text like source code. But so does a common > default for the tab size, But there's no such thing as "default tab size". Configuring the tab-size is quite common among programmers. But why do you insist on using tabs at all? The best way -- in my opinion -- is to use the tab- and backspace-key for indentation, and let the editor convert it to spaces. (And use some tool to convert all tabs in the old code.) I don't see *any* advantage of mixed spaces and tabs, but quite some disadvantages/problems. > What I would expect is some option in python to make tabs work the > way they used to. I want a choice for me to preserve my settings, > the same way you want to preserve yours. > > What I want should not be much to ask, since this is how python 2 > used to do things. > > I admit such a '--fixed-tabs' option, that will make tab stops be 8 > columns apart, and allow any number of spaces like in python 2, > makes the code I write dependent on that option. There's no need to add this to Python 3, since you already have what you want. Simply use: expand yourscript.py | python3 regards Roland