MCPcopy Index your code
hub / github.com/python/cpython / suspend_history

Method suspend_history

Lib/_pyrepl/historical_reader.py:296–302  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

294
295 @contextmanager
296 def suspend_history(self) -> SimpleContextManager:
297 try:
298 old_history = self.history[:]
299 del self.history[:]
300 yield
301 finally:
302 self.history[:] = old_history
303
304 def prepare(self) -> None:
305 super().prepare()

Callers 2

suspendMethod · 0.95
maybe_run_commandFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected