Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.datemas.de!rt.uk.eu.org!newsfeed.xs4all.nl!newsfeed1.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; 'languages.': 0.04; 'syntax': 0.04; 'arguments': 0.09; 'cc:addr:python-list': 0.11; 'python': 0.11; 'assume': 0.14; 'comma': 0.16; 'comma,': 0.16; 'from:addr:cs': 0.16; 'from:addr:zip.com.au': 0.16; 'from:name:cameron simpson': 0.16; 'message-id:@cskk.homeip.net': 0.16; 'ought': 0.16; 'received:211.29': 0.16; 'received:211.29.132': 0.16; 'received:optusnet.com.au': 0.16; 'received:syd.optusnet.com.au': 0.16; 'sees': 0.16; 'seperated.': 0.16; 'simpson': 0.16; 'wrote:': 0.18; 'all,': 0.19; 'cc:addr:gmail.com': 0.22; 'separate': 0.22; 'shell': 0.22; 'cc:addr:python.org': 0.22; 'cc:2**1': 0.23; 'header:User- Agent:1': 0.23; 'either.': 0.24; 'cc:no real name:2**0': 0.24; 'source': 0.25; 'header:In-Reply-To:1': 0.27; 'function': 0.29; 'michael': 0.29; 'skip:= 40': 0.31; 'totally': 0.33; 'subject:from': 0.34; 'subject: (': 0.35; "can't": 0.35; 'are,': 0.36; 'received:com.au': 0.36; 'right?': 0.36; "didn't": 0.36; 'two': 0.37; 'received:211': 0.38; 'matter': 0.61; 'content- disposition:inline': 0.62; 'to:addr:gmail.com': 0.65; 'u.s.': 0.71; 'safe': 0.72; 'why?': 0.91 Date: Fri, 7 Jun 2013 18:56:26 +1000 From: Cameron Simpson To: =?utf-8?B?zp3Ouc66z4zOu86xzr/PgiDOms6/z43Pgc6xz4I=?= Subject: Re: Changing filenames from Greeklish => Greek (subprocess complain) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <51B19587.8030801@gmail.com> User-Agent: Mutt/1.5.21 (2010-09-15) References: <51B19587.8030801@gmail.com> X-Optus-CM-Score: 0 X-Optus-CM-Analysis: v=2.0 cv=eqSHVfVX c=1 sm=1 a=wom5GMh1gUkA:10 a=AdgiQdVXbpoA:10 a=IkcTkHD0fZMA:10 a=vrnE16BAAAAA:8 a=ZtCCktOnAAAA:8 a=uw23S90zXSUA:10 a=pGLkceISAAAA:8 a=bp_1EJjyaEqv2nQWc_oA:9 a=QEXdDO2ut3YA:10 a=MSl-tDqOz04A:10 a=ChdAjXE5lkUvdteQbhpnkQ==:117 Cc: python-list@python.org 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: 23 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1370595402 news.xs4all.nl 15963 [2001:888:2000:d::a6]:40655 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:47320 On 07Jun2013 11:10, =?utf-8?B?zp3Or866zr/PgiDOk866z4EzM866?= wrote: | On 7/6/2013 10:42 πμ, Michael Weylandt wrote: | >os.rename( filepath_bytes filepath.encode('utf-8') | >Missing comma, which is, after all, just a matter of syntax so it can't matter, right? | | I doubted that os.rename arguments must be comma seperated. Why? Every other python function separates arguments with commas. | 'mv source target' didn't require commas so i though it was safe to assume that os.rename did not either. "mv" is shell syntax. os.rename is Python syntax. Two totally separate languages. -- Cameron Simpson Cynic, n. A blackguard whose faulty vision sees things as they are, not as they ought to be. Ambrose Bierce (1842-1914), U.S. author. The Devil's Dictionary (1881-1906).