Python's 8-bit cleanness deprecated?

Jarek Zgoda jzgoda at usun.gazeta.pl
Tue Feb 11 00:50:53 EST 2003


Roman Suzi <rnd at onego.ru> pisze:

>>> And also, for a windows program which encoding do I specify? Windows console
>>> historically uses cp866 while GUI uses cp1251.
>>
>>We have cp437 for Windows console as default encoding, while _really_
>>it's something different... You don't have "ą" character in cp437 set,
>>but you can do
>>
>>print "Zażółć gęślą jaźń".encode('cp437')
>>
>>and it will be shown correctly.
> 
> OK. Let's have a real life test of PEP 263.  Could you please send it in
> attachment file (as a binary) with a proper encoding indicated by -*-
> coding-cookie? (Maybe even to c.l.p - so large audience could confirm encoding
> declaration helps read and run your program on Python 2.3 ).
> 
> (I hope you do have Python 2.3a to test it on your computer.)

Not yet, but I'll try to install the beast today evening. This behavior
was observed using 2.2.1 and 2.2.2 on Windows NT4SP6a, locale set to
Polish, but system character encoding left default (I think it's
cp1252). Anyway, I don't think it's a Python problem, rather Windows
fault.

-- 
Jarek Zgoda
http://www.zgoda.biz/
JID:jarek at jabberpl.org




More information about the Python-list mailing list