[issue6082] os.path.sameopenfile reports that standard streams are the same

Philip Jenvey report at bugs.python.org
Fri May 22 03:45:55 CEST 2009


Philip Jenvey <pjenvey at users.sourceforge.net> added the comment:

They are the same file, namely your tty

Python 2.6 (r26:66714, Oct  8 2008, 22:16:30) 
[GCC 4.0.1 (Apple Inc. build 5465)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import os, sys
>>> [os.ttyname(fp.fileno()) for fp in sys.stdin, sys.stdout, sys.stderr]
['/dev/ttys002', '/dev/ttys002', '/dev/ttys002']

----------
nosy: +pjenvey

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue6082>
_______________________________________


More information about the Python-bugs-list mailing list