Terry J. Reedy added the comment:

'crash' means OS message rather than Python exiting with exception traceback 
and message.

Can you post a minimal reproducer?  What OS?  subprocess.Popen._get_handles is 
different on POSIX and windows, though both seem to call f.fileno() without 
try-except. 

All filenoes are initialized to -1, so it seems to me that either
a. all accesses should be wrapped with try-except: pass, or
b. subprocess doc should say that file-like objects must include a fileno 
method returning -1.

I am puzzled though.  The 2.7 doc for (builtin)file.fileno() says 
"
Note
File-like objects which do not have a real file descriptor should not provide 
this method! "
"
Rather than return -1

In must be that the subprocess test does not test with a 'file-like object 
without a file descriptor'

----------
nosy: +terry.reedy
type: crash -> behavior

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

Reply via email to