Path: csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed3.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.000 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'subject:Python': 0.06; '*not*': 0.07; 'binary': 0.07; 'installed.': 0.07; 'lines,': 0.07; 'modifying': 0.07; 'python3': 0.07; 'bash': 0.09; 'default.': 0.09; 'dependency': 0.09; 'line:': 0.09; 'skip:/ 10': 0.09; 'wrapper': 0.09; 'runs': 0.10; 'python': 0.11; 'language.': 0.14; 'collections': 0.16; 'dependency,': 0.16; 'from:addr:torriem': 0.16; 'from:name:michael torrie': 0.16; 'path.': 0.16; 'trivially': 0.16; 'wrote:': 0.18; 'developer,': 0.19; 'command': 0.22; 'shell': 0.22; 'install': 0.23; 'header:User-Agent:1': 0.23; 'sorry,': 0.24; 'developers': 0.25; 'script': 0.25; 'header:In- Reply-To:1': 0.27; 'installed': 0.27; "i'm": 0.30; '(which': 0.31; 'gives': 0.31; 'you?': 0.31; 'argue': 0.31; 'away.': 0.31; 'bad.': 0.31; "d'aprano": 0.31; 'invoke': 0.31; 'steven': 0.31; 'yesterday': 0.31; 'anyone': 0.31; 'run': 0.32; 'another': 0.32; 'cases': 0.33; 'sense': 0.34; 'maybe': 0.34; 'subject:the': 0.34; 'could': 0.34; "can't": 0.35; 'but': 0.35; 'there': 0.35; 'adjust': 0.36; 'done': 0.36; 'doing': 0.36; 'application': 0.37; 'too': 0.37; 'message-id:@gmail.com': 0.38; 'to:addr:python-list': 0.38; 'pm,': 0.38; 'does': 0.39; 'to:addr:python.org': 0.39; 'received:org': 0.40; 'how': 0.40; 'most': 0.60; 'affect': 0.61; 'matter': 0.61; 'course': 0.61; 'refer': 0.63; 'more': 0.64; 'charset:windows-1252': 0.65; 'life': 0.66; 'therefore': 0.72; 'apart': 0.72 X-Virus-Scanned: amavisd-new at torriefamily.org Date: Mon, 16 Mar 2015 20:14:20 -0600 From: Michael Torrie User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.5.0 MIME-Version: 1.0 To: python-list@python.org Subject: Re: Python 2 to 3 conversion - embrace the pain References: <20150316025301.GA94576@cskk.homeip.net> <873855tts4.fsf@jester.gateway.sonic.net> <55068cb0$0$12923$c3e8da3$5496439d@news.astraweb.com> <8761a1gxhq.fsf@jester.gateway.sonic.net> <55073edd$0$13014$c3e8da3$5496439d@news.astraweb.com> In-Reply-To: <55073edd$0$13014$c3e8da3$5496439d@news.astraweb.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.19 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: 37 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1426558465 news.xs4all.nl 2967 [2001:888:2000:d::a6]:58710 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:87592 On 03/16/2015 02:36 PM, Steven D'Aprano wrote: > I'm sorry, that makes no sense to me. What does it matter whether Python3 is > installed to /opt or /usr or /bin or /who/the/feck/cares, so long as your > application runs when you run it? It's just another dependency, and no more > than one call to yum away. Of course it matters. How else will you refer to it in the #! invocation? If Python3 is in the system path then you can use a wrapper script like Calibre does. But in the case of RHEL with Software Collections (which does use yum), it does not place it in the system path. > Yesterday I wrote: > > Alas, too many (Linux) developers insist on using the system Python > as their application language. In most cases they could trivially > run "aptitude install python3" and be done with it, but that's an > extra dependency and therefore Bad. > > I never imagined that anyone would argue that they can't install and use > Python3 because of the location where it is installed. As an application > developer, apart from ensuring that the PATH is setup correctly and maybe > having to adjust a few hash-bang lines, how does the location of the Python > binary affect you? Well the thing is that it's *not* in the PATH by default. So it does affect me. The official way to use Python 3 in RHEL Software Collection is to invoke with with this command line: scl enable python33 bash This gives you a shell where python3 is in the path. You can put Python3 in the path permanently by modifying /etc/profile. There are good reasons for SCL doing things this way, and it's not the only way. Just pointing out that distro life isn't always rosy.