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 sgala
Recipients
Date 2007-06-28.12:59:15
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
Still:

$ python -c "import codecs,sys; sys.stdout = codecs.getwriter('utf-8')(sys.stdout); print sys.stdout.encoding" 
UTF-8
$ python -c "import codecs,sys; sys.stdout = codecs.getwriter('utf-8')(sys.stdout); print sys.stdout.encoding" | cat
None

but now, at least


$ python -c "import codecs,sys; sys.stdout = codecs.getwriter('utf-8')(sys.stdout); print unicode('á %s' % 'éí','utf8') "
á éí
$ python -c "import codecs,sys; sys.stdout = codecs.getwriter('utf-8')(sys.stdout); print unicode('á %s' % 'éí','utf8') " | cat
á éí

can be piped.

It still looks amazing to me that people is happy with this behavior.

Waiting anxiously to see how this is dealt with in the str/unicode unification coming for python 3000...
Santiago :)
History
Date User Action Args
2007-08-23 14:52:07adminlinkissue1668295 messages
2007-08-23 14:52:07admincreate