Kaydet (Commit) 28274ab6 authored tarafından Vinay Sajip's avatar Vinay Sajip

Issue #5971: StreamHandler.handleError now swallows IOErrors which occur when…

Issue #5971: StreamHandler.handleError now swallows IOErrors which occur when trying to print a traceback.
üst 26f32557
...@@ -720,7 +720,11 @@ class Handler(Filterer): ...@@ -720,7 +720,11 @@ class Handler(Filterer):
""" """
if raiseExceptions: if raiseExceptions:
ei = sys.exc_info() ei = sys.exc_info()
try:
traceback.print_exception(ei[0], ei[1], ei[2], None, sys.stderr) traceback.print_exception(ei[0], ei[1], ei[2], None, sys.stderr)
except IOError:
pass # see issue 5971
finally:
del ei del ei
class StreamHandler(Handler): class StreamHandler(Handler):
......
...@@ -40,6 +40,9 @@ Core and Builtins ...@@ -40,6 +40,9 @@ Core and Builtins
Library Library
------- -------
- Issue #5971: StreamHandler.handleError now swallows IOErrors which occur when
trying to print a traceback.
- Issue 5955: aifc's close method did not close the file it wrapped, - Issue 5955: aifc's close method did not close the file it wrapped,
now it does. This also means getfp method now returns the real fp. now it does. This also means getfp method now returns the real fp.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment