Message195861
Use cp1256 encoding in your source file. It is expected that usually your source files encoding is same as your locale encoding. In such case printing string literals and Unicode string literals produces same result (as they look in the sources).
s1 is '\xd8\xb3\xd9\x84\xd8\xa7\xd9\x85' (u'سلام'.encode('utf-8')) and when it printed in utf-8 locale it produces "سلام", but when it printed in cp1256 locale it produces a mojibake.
When you convert your source file to cp1256 and change a header, s1 will be '\xd3\xe1\xc7\xe3' (u'سلام'.encode('cp1256')) and will produce "سلام" when printed in your cp1256 locale. |
|
Date |
User |
Action |
Args |
2013-08-22 06:08:52 | serhiy.storchaka | set | recipients:
+ serhiy.storchaka, loewis, terry.reedy, kbk, ned.deily, ezio.melotti, roger.serwy, r.david.murray, asvetlov, THRlWiTi, alex.hartwig, pradyunsg, Tomoki.Imai |
2013-08-22 06:08:52 | serhiy.storchaka | set | messageid: <1377151732.5.0.172361307333.issue15809@psf.upfronthosting.co.za> |
2013-08-22 06:08:52 | serhiy.storchaka | link | issue15809 messages |
2013-08-22 06:08:52 | serhiy.storchaka | create | |
|