Python 3.3, gettext and Unicode problems

Marcel Rodrigues marcelgmr at gmail.com
Sun Dec 30 21:45:33 EST 2012


Thank you Terry!

I was trying to follow the documentation but somehow didn't payed attention
to the lgettext/gettext distinction until I read your first response.
Changing lgettext to gettext solved the problem.

It prints correctly to my console because I have to environmental
variable PYTHONIOENCODING set to utf8, which is what my console emulator
uses. But that's actually not necessary in my original application (it has
a web interface), just for this isolated test. I really should have
separated the call to print() as you suggested tough, if only to make the
problem clearer.

As for the "multiple different limited national encodings" vs "everything
as UTF-8", I agree with you and am definitely going for the latter because
the former seems to be unnecessarily complicated.

Thanks again for the help! Problem solved.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20121231/7a3a8b45/attachment.html>


More information about the Python-list mailing list