Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
611 changes: 279 additions & 332 deletions Lib/idlelib/debugger.py

Large diffs are not rendered by default.

8 changes: 8 additions & 0 deletions Lib/idlelib/filelist.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,14 @@ def open(self, filename, action=None):
edit._close()
return None

def already_open(self, filename):
assert filename
filename = self.canonize(filename)
if not os.path.isdir(filename):
key = os.path.normcase(filename)
return key in self.dict
return False

def gotofileline(self, filename, lineno=None):
edit = self.open(filename)
if edit is not None and lineno is not None:
Expand Down
7 changes: 7 additions & 0 deletions Lib/idlelib/pyshell.py
Original file line number Diff line number Diff line change
Expand Up @@ -463,6 +463,7 @@ def restart_subprocess(self, with_cwd=False, filename=''):
debugger_r.close_subprocess_debugger(self.rpcclt)
except:
pass
debug.endexecuting()
# Kill subprocess, spawn a new one, accept connection.
self.rpcclt.close()
self.terminate_subprocess()
Expand Down Expand Up @@ -782,6 +783,8 @@ def runcode(self, code):
if self.tkconsole.canceled:
self.tkconsole.canceled = False
print("KeyboardInterrupt", file=self.tkconsole.stderr)
if self.interp.debugger:
self.interp.debugger.endexecuting()
else:
self.showtraceback()
finally:
Expand Down Expand Up @@ -967,11 +970,15 @@ def open_debugger(self):

def beginexecuting(self):
"Helper for ModifiedInterpreter"
if self.interp.debugger:
self.interp.debugger.beginexecuting()
self.resetoutput()
self.executing = 1

def endexecuting(self):
"Helper for ModifiedInterpreter"
if self.interp.debugger:
self.interp.debugger.endexecuting()
self.executing = 0
self.canceled = 0
self.showprompt()
Expand Down
Binary file added lib/idlelib/icons/debug_current.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added lib/idlelib/icons/debug_go.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added lib/idlelib/icons/debug_go_disabled.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added lib/idlelib/icons/debug_line.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added lib/idlelib/icons/debug_out.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added lib/idlelib/icons/debug_out_disabled.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added lib/idlelib/icons/debug_over.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added lib/idlelib/icons/debug_over_disabled.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added lib/idlelib/icons/debug_prefs.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added lib/idlelib/icons/debug_prefs_disabled.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added lib/idlelib/icons/debug_step.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added lib/idlelib/icons/debug_step_disabled.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added lib/idlelib/icons/debug_stop.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added lib/idlelib/icons/debug_stop_disabled.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.