MCPcopy Index your code
hub / github.com/RustPython/RustPython / run_hooks

Method run_hooks

Lib/_pyrepl/reader.py:727–743  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

725 self.finish()
726
727 def run_hooks(self) -> None:
728 threading_hook = self.threading_hook
729 if threading_hook is None and 'threading' in sys.modules:
730 from ._threading_handler import install_threading_hook
731 install_threading_hook(self)
732 if threading_hook is not None:
733 try:
734 threading_hook()
735 except Exception:
736 pass
737
738 input_hook = self.console.input_hook
739 if input_hook:
740 try:
741 input_hook()
742 except Exception:
743 pass
744
745 def handle1(self, block: bool = True) -> bool:
746 """Handle a single event. Wait as long as it takes if block

Callers 1

handle1Method · 0.95

Calls 1

install_threading_hookFunction · 0.85

Tested by

no test coverage detected