Reset the counter to zero. Use this when a logical process restarts without restarting the actual python process.
(self)
| 343 | self._value.set_exemplar(Exemplar(exemplar, amount, time.time())) |
| 344 | |
| 345 | def reset(self) -> None: |
| 346 | """Reset the counter to zero. Use this when a logical process restarts without restarting the actual python process.""" |
| 347 | self._value.set(0) |
| 348 | self._created = time.time() |
| 349 | |
| 350 | def count_exceptions(self, exception: Union[Type[BaseException], Tuple[Type[BaseException], ...]] = Exception) -> ExceptionCounter: |
| 351 | """Count exceptions in a block of code or function. |