mirror of
https://github.com/python/cpython.git
synced 2025-12-05 00:52:25 +00:00
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:
parent
f4d087964e
commit
d1e4917e06
2 changed files with 2 additions and 0 deletions
|
|
@ -239,6 +239,7 @@ def print_exception():
|
||||||
efile = sys.stderr
|
efile = sys.stderr
|
||||||
typ, val, tb = excinfo = sys.exc_info()
|
typ, val, tb = excinfo = sys.exc_info()
|
||||||
sys.last_type, sys.last_value, sys.last_traceback = excinfo
|
sys.last_type, sys.last_value, sys.last_traceback = excinfo
|
||||||
|
sys.last_exc = val
|
||||||
seen = set()
|
seen = set()
|
||||||
|
|
||||||
def print_exc(typ, exc, tb):
|
def print_exc(typ, exc, tb):
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1 @@
|
||||||
|
Support ``sys.last_exc`` in :mod:`idlelib`.
|
||||||
Loading…
Add table
Add a link
Reference in a new issue