Message70813
FWIW I also tried the fix on a Windows box with Python 2.5.1. The
failure there is different since the Windows command prompt apparently
uses cp437 as its encoding:
Python 2.5.1 (r251:54863, Apr 18 2007, 08:51:08) [MSC v.1310 32 bit
(Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> ustr = u'¿Cómo'
>>> ustr
u'\xbfC\xf3mo'
>>> print ustr
¿Cómo
>>> import code
>>> code.interact()
Python 2.5.1 (r251:54863, Apr 18 2007, 08:51:08) [MSC v.1310 32 bit
(Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
(InteractiveConsole)
>>> ustr = u'¿Cómo'
>>> print ustr
Traceback (most recent call last):
File "<console>", line 1, in <module>
File "d:\bin\Python2.5.1\lib\encodings\cp437.py", line 12, in encode
return codecs.charmap_encode(input,errors,encoding_map)
UnicodeEncodeError: 'charmap' codec can't encode character u'\xa8' in
position 0: character maps to <undefined>
Applying the patch resulted in correct behavior on Windows as well. |
|
Date |
User |
Action |
Args |
2008-08-07 05:12:39 | kmtracey | set | recipients:
+ kmtracey, birkenfeld, vstinner |
2008-08-07 05:12:39 | kmtracey | set | messageid: <1218085959.24.0.500777274698.issue1288615@psf.upfronthosting.co.za> |
2008-08-07 05:12:38 | kmtracey | link | issue1288615 messages |
2008-08-07 05:12:37 | kmtracey | create | |
|