Path: csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder2.hal-mli.net!newsfeed.xs4all.nl!newsfeed4.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.000 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; '"""': 0.05; 'error:': 0.05; 'upgraded': 0.05; '(especially': 0.07; 'utf-8': 0.07; 'python': 0.09; '*is*': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'terry': 0.09; 'unexpected': 0.09; 'unicode,': 0.09; '2.7': 0.13; 'encoding': 0.15; '(ie,': 0.16; '3.3,': 0.16; 'also:': 0.16; 'encoders': 0.16; 'presume': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'reedy': 0.16; 'retrieving': 0.16; 'subject:Unicode': 0.16; 'url:mi': 0.16; 'version).': 0.16; 'wrote:': 0.17; 'fix': 0.17; 'unicode': 0.17; 'jan': 0.18; 'windows': 0.19; 'do.': 0.21; 'http': 0.22; "i've": 0.23; 'seems': 0.23; '(this': 0.24; 'script': 0.24; 'tried': 0.25; 'header:In-Reply-To:1': 0.25; 'header:User-Agent:1': 0.26; 'setting': 0.26; 'bugs': 0.27; 'skip:e 30': 0.27; 'fixed': 0.28; 'header:X-Complaints-To:1': 0.28; 'run': 0.28; 'probably': 0.29; "i'm": 0.29; 'maybe': 0.29; 'error': 0.30; 'print': 0.32; 'idle': 0.33; 'to:addr:python-list': 0.33; 'changed': 0.34; 'screen': 0.34; 'said,': 0.35; 'pm,': 0.35; 'there': 0.35; 'received:org': 0.36; 'but': 0.36; 'does': 0.37; 'subject:: ': 0.38; 'page': 0.38; 'gives': 0.39; 'to:addr:python.org': 0.39; 'header:Received:5': 0.40; 'containing': 0.61; 'side': 0.61; 'url:index': 0.61; 'solve': 0.62; 'multilingual': 0.65; 'url:cgi': 0.65; 'sans': 0.71; '3:00': 0.84; 'happier': 0.84; 'received:fios.verizon.net': 0.84; 'url:lang': 0.84; 'url:biz': 0.91; 'url:fr': 0.95 X-Injected-Via-Gmane: http://gmane.org/ To: python-list@python.org From: Terry Reedy Subject: Re: Unicode Date: Mon, 17 Dec 2012 17:03:21 -0500 References: <50ceb674$0$29868$c3e8da3$5496439d@news.astraweb.com> <50CF5F72.90402@davea.name> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Gmane-NNTP-Posting-Host: pool-173-75-251-66.phlapa.fios.verizon.net User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:16.0) Gecko/20121026 Thunderbird/16.0.2 In-Reply-To: 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: 36 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1355781824 news.xs4all.nl 6844 [2001:888:2000:d::a6]:39246 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:35021 On 12/17/2012 3:00 PM, Anatoli Hristov wrote: >> I fixed the print, I changed the setting of the terminal and also on >> the sshconfig, so now when I print I'm able to print out without >> problems, but when I tried to run the script I've made it gives me >> again the same error : >> ""Unexpected error: exceptions.UnicodeEncodeError >> """ >> Maybe I will try to update to 2.7 > > Upgraded to python 27 and still it gives Unexpected error: > exceptions.UnicodeEncodeError. Damn encoders I don'y know what to > do... If you are working with unicode, and you can upgrade to 3.3, you will probably we happier if you do. This does not solve all problems, but the python side is definitely better. (IE, there are unicode bugs in 2.7 whose fix *is* to upgrade to 3.3.) That said, retrieving http://prf.icecat.biz/index.cgi?product_id=14688538;mi=start;smi=product;shopname=openICEcat-url;lang=fr with Firefox on Win 7 returns a page containing so I presume the http encoding is also utf-8 Also: printing to the screen in IDLE may work better than with the standard interactive console (especially the awful Windows version). I have the font set to Lucida Sans Unicode (this may be windows specific) which seems to works for all BMP (Basic Multilingual Plane) chars. -- Terry Jan Reedy