3 # © Copyright 2021-2022, Scott Gasch
5 """Some exceptions used elsewhere."""
7 # This module is commonly used by others in here and should avoid
8 # taking any unnecessary dependencies back on them.
11 class PreconditionException(AssertionError):
12 """Use to indicate function preconditions violated."""
17 class PostconditionException(AssertionError):
18 """Use to indicate function postconditions violated."""
23 class TimeoutError(Exception):
24 """Use to indicate an operation that timed out."""
26 def __init__(self, value: str = "Timed out"):
31 return repr(self.value)