[issue21497] faulthandler should handle sys.stderr being None gracefully

STINNER Victor report at bugs.python.org
Tue May 13 18:09:47 CEST 2014


STINNER Victor added the comment:

> This means there's an unexpected gotcha

I prefer to see an exception before sys.stderr is None, instead of not seeing the traceback when the application does crash. It is usually a pain to reproduce a crash in the exact same conditions.

> if I want my application to still run under Windows when the user has changed the default, I first have to check sys.stderr before enabling faulthandler.

Exactly. It's not really specific to Windows, you may also have sys.stderr on UNIX in some cases.

----------

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


More information about the Python-bugs-list mailing list