projects
/
python_utils.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
mypy clean!
[python_utils.git]
/
exceptions.py
diff --git
a/exceptions.py
b/exceptions.py
index 3ce94d365774422252ab591303907d31ff65d1ba..82a82a566b1b1da50af1942364761722c09f047c 100644
(file)
--- a/
exceptions.py
+++ b/
exceptions.py
@@
-1,5
+1,9
@@
#!/usr/bin/env python3
#!/usr/bin/env python3
+# This module is commonly used by others in here and should avoid
+# taking any unnecessary dependencies back on them.
+
+
class PreconditionException(AssertionError):
pass
class PreconditionException(AssertionError):
pass
@@
-9,5
+13,8
@@
class PostconditionException(AssertionError):
class TimeoutError(Exception):
class TimeoutError(Exception):
- pass
+ def __init__(self, value: str = "Timed out"):
+ self.value = value
+ def __str__(self):
+ return repr(self.value)