gh-102778: IDLE - make sys.last_exc available in Shell after traceback (#103314)

---------
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
This commit is contained in:
Irit Katriel 2023-04-19 06:05:52 +01:00 committed by GitHub
parent f4d087964e
commit d1e4917e06
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 0 deletions

View File

@ -239,6 +239,7 @@ def print_exception():
efile = sys.stderr
typ, val, tb = excinfo = sys.exc_info()
sys.last_type, sys.last_value, sys.last_traceback = excinfo
sys.last_exc = val
seen = set()
def print_exc(typ, exc, tb):

View File

@ -0,0 +1 @@
Support ``sys.last_exc`` in :mod:`idlelib`.