Method
__exit__
(
self,
exc_type: type[BaseException] | None,
exc_val: BaseException | None,
exc_tb: TracebackType | None,
)
Source from the content-addressed store, hash-verified
| 83 | self.start = time.monotonic() |
| 84 | |
| 85 | def __exit__( |
| 86 | self, |
| 87 | exc_type: type[BaseException] | None, |
| 88 | exc_val: BaseException | None, |
| 89 | exc_tb: TracebackType | None, |
| 90 | ) -> Literal[False]: |
| 91 | self.last_command = time.monotonic() - self.start |
| 92 | self.running_time += self.last_command |
| 93 | return False |
| 94 | |
| 95 | def reset_timer(self) -> None: |
| 96 | self.running_time = 0.0 |
Tested by
no test coverage detected