Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!feeder.news-service.com!xlned.com!feeder5.xlned.com!newsfeed.xs4all.nl!newsfeed5.news.xs4all.nl!xs4all!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.007 X-Spam-Evidence: '*H*': 0.99; '*S*': 0.00; 'bits': 0.07; 'python': 0.07; '16-bit': 0.09; '32-bit': 0.09; 'utf-8': 0.09; 'pm,': 0.11; 'output': 0.12; 'wrote:': 0.14; 'encodings,': 0.16; 'received:203.24': 0.16; 'subject:unicode': 0.16; 'code': 0.22; 'header:In-Reply-To:1': 0.22; 'thu,': 0.22; 'purposes.': 0.23; 'byte': 0.25; "i'm": 0.26; 'changed': 0.27; 'looks': 0.28; 'external': 0.29; 'unicode': 0.29; 'confused': 0.31; 'to:addr :python-list': 0.32; 'character': 0.33; 'uses': 0.34; 'using': 0.34; 'header:User-Agent:1': 0.35; 'case,': 0.36; 'either': 0.37; 'sequence': 0.38; 'but': 0.38; 'so,': 0.38; 'used': 0.38; 'to:addr:python.org': 0.39; '2011': 0.62; 'reply-to:no real name:2**0': 0.72; 'header:Reply-To:1': 0.72; 'here...': 0.91 In-Reply-To: References: <4dcb50f8$0$29973$c3e8da3$5496439d@news.astraweb.com> Date: Thu, 12 May 2011 14:14:35 +1000 Subject: Re: unicode by default From: "John Machin" To: python-list@python.org User-Agent: SquirrelMail/1.4.21 MIME-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Priority: 3 (Normal) Importance: Normal X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.12 Precedence: list Reply-To: sjmachin@lexicon.net 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: 14 NNTP-Posting-Host: 82.94.164.166 X-Trace: 1305173678 news.xs4all.nl 81478 [::ffff:82.94.164.166]:46916 X-Complaints-To: abuse@xs4all.nl Xref: x330-a1.tempe.blueboxinc.net comp.lang.python:5195 On Thu, May 12, 2011 1:44 pm, harrismh777 wrote: > By > default it looks like Python3 is writing output with UTF-8 as default... > and I thought that by default Python3 was using either UTF-16 or UTF-32. > So, I'm confused here... also, I used the character sequence \u00A3 > which I thought was UTF-16... but Python3 changed my intent to 'c2a3' > which is the normal UTF-8... Python uses either a 16-bit or a 32-bit INTERNAL representation of Unicode code points. Those NN bits have nothing to do with the UTF-NN encodings, which can be used to encode the codepoints as byte sequences for EXTERNAL purposes. In your case, UTF-8 has been used as it is the default encoding on your platform.