Fuzzyman wrote:
How does the print statement decode unicode strings itis passed ? (By
that I mean which encoding does it use).
sys.stdout.encoding
Under windows it doesn't appear to use defaultencoding. On my system
the default encoding is ascii, yet the terminal encoding is latin1 (or
cp1252 or whatever, but not ascii). This means that print '£' works
fine, yet unicode('£') will raise the UnicodeDecodeError.
This uses sys.defaultencoding
Kent
--
http://mail.python.org/mailman/listinfo/python-list