gh-102778: revert changes to idlelib (#102825)

This commit is contained in:
Irit Katriel 2023-03-19 16:19:59 +00:00 committed by GitHub
parent ccb5af7bfe
commit 4d1f033986
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 9 additions and 24 deletions

View file

@ -1367,14 +1367,11 @@ class PyShell(OutputWindow):
if self.interp.rpcclt:
return self.interp.remote_stack_viewer()
try:
if hasattr(sys, 'last_exc'):
sys.last_exc.__traceback__
else:
sys.last_traceback
sys.last_traceback
except:
messagebox.showerror("No stack trace",
"There is no stack trace yet.\n"
"(sys.last_exc and sys.last_traceback are not defined)",
"(sys.last_traceback is not defined)",
parent=self.text)
return
from idlelib.stackviewer import StackBrowser