This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author massysett
Recipients
Date 2007-06-27.11:29:43
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
The fix given by gbrandl, which is to use 

sys.stdout = codecs.EncodedFile(sys.stdout, 'utf-8')

does not work. EncodedFile expects to receive encoded strings, so if you try to use it with Unicode strings, you get errors. I could of course 

I tried

sys.stdout = codecs.open(sys.stdout, 'w', 'utf-8')

but that gives me "Type Error: coercing to Unicode: need string or buffer, file found."

Since this was (absurdly) closed as invalid, are there any good fixes that actually work?
History
Date User Action Args
2007-08-23 14:52:07adminlinkissue1668295 messages
2007-08-23 14:52:07admincreate