Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!news.mixmin.net!rt.uk.eu.org!newsfeed.xs4all.nl!newsfeed3a.news.xs4all.nl!xs4all!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.001 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'from:addr:yahoo.co.uk': 0.04; 'versions.': 0.07; '2to3': 0.09; 'lawrence': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'starter': 0.09; 'will,': 0.09; 'python': 0.11; 'project,': 0.12; 'language.': 0.14; 'presume': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'worst': 0.16; 'subject:python': 0.16; 'so.': 0.16; 'language': 0.16; 'wrote:': 0.18; 'library': 0.18; 'seems': 0.21; 'header:User-Agent:1': 0.23; 'decide': 0.24; 'fine': 0.24; 'versions': 0.24; '---': 0.24; 'script': 0.25; 'header:X-Complaints-To:1': 0.27; 'header:In-Reply-To:1': 0.27; 'idea': 0.28; 'feature': 0.29; 'code': 0.31; 'getting': 0.31; 'alan': 0.31; 'libraries': 0.31; 'run': 0.32; 'skip:# 10': 0.33; 'agree': 0.35; 'test': 0.35; 'there': 0.35; 'really': 0.36; 'in.': 0.36; "didn't": 0.36; 'too': 0.37; 'two': 0.37; 'to:addr:python- list': 0.38; 'that,': 0.38; 'to:addr:python.org': 0.39; 'received:org': 0.40; 'even': 0.60; 'free': 0.61; 'no.': 0.61; 'viruses': 0.61; 'protection': 0.63; 'our': 0.64; 'between': 0.67; 'antivirus': 0.68; 'meyer': 0.84 X-Injected-Via-Gmane: http://gmane.org/ To: python-list@python.org From: Mark Lawrence Subject: Re: running python 2 vs 3 Date: Thu, 20 Mar 2014 20:22:33 +0000 References: <87ob10nbeh.fsf@elektro.pacujo.net> <532B4750.2090006@yahoo.com> <87eh1wpr96.fsf@elektro.pacujo.net> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Gmane-NNTP-Posting-Host: host-78-146-8-179.as13285.net User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 In-Reply-To: <87eh1wpr96.fsf@elektro.pacujo.net> X-Antivirus: avast! (VPS 140319-1, 19/03/2014), Outbound message X-Antivirus-Status: Clean 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: 40 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1395346968 news.xs4all.nl 2830 [2001:888:2000:d::a6]:37677 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:68609 On 20/03/2014 20:08, Marko Rauhamaa wrote: > Alan Meyer : > >> I presume it would still be a good idea to test both python >> interpreters against any script that you didn't knowingly write with a >> feature that will only work in one of the two python versions. >> >> If it works fine in both - and many will, then use: >> >> #!/usr/bin/env python >> >> Only use the "python2" or "python3" versions if you really have a >> reason to do so. >> >> Yes? No? > > No. Even if you managed to do that, it would mean getting the worst of > both worlds. The language dialects are too far apart. When you start > your Python project, you decide between Python 2 and Python 3 and go all > in. > > Marko > I do not agree that the dialects are too far apart, not that it really matters. There are several libraries available to enable code to run under both versions. The starter is 2to3 which had been in the standard library for what seems like an eternity to me. -- My fellow Pythonistas, ask not what our language can do for you, ask what you can do for our language. Mark Lawrence --- This email is free from viruses and malware because avast! Antivirus protection is active. http://www.avast.com