Éric Araujo added the comment:

One could argue that since print does respect the terminal encoding if 
sys.stdin is a tty, pydoc could be as smart and do the same.  I think the 
problem comes from the use of a pager, which means a subprocess, which mean 
that the streams are not ttys and the encoding can’t be detected.  print 
doesn’t work either with pipes: python -c "import foo; print foo.__author__" | 
cat

So I fear that this bug may only get a doc note.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue15791>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to