MCPcopy Create free account
hub / github.com/bpython/bpython / sigtstp_handler

Method sigtstp_handler

bpython/curtsiesfrontend/repl.py:620–626  ·  view source on GitHub ↗
(self, signum: int, frame: FrameType | None)

Source from the content-addressed store, hash-verified

618 )
619
620 def sigtstp_handler(self, signum: int, frame: FrameType | None) -> None:
621 self.scroll_offset = len(self.lines_for_display)
622 self.__exit__(None, None, None)
623 self.on_suspend()
624 os.kill(os.getpid(), signal.SIGTSTP)
625 self.after_suspend()
626 self.__enter__()
627
628 def clean_up_current_line_for_exit(self):
629 """Called when trying to exit to prep for final paint"""

Callers

nothing calls this directly

Calls 4

__exit__Method · 0.95
on_suspendMethod · 0.95
after_suspendMethod · 0.95
__enter__Method · 0.95

Tested by

no test coverage detected