diff options
| author | jwijenbergh <jeroenwijenbergh@protonmail.com> | 2022-10-18 10:55:34 +0200 |
|---|---|---|
| committer | jwijenbergh <jeroenwijenbergh@protonmail.com> | 2022-10-18 15:01:13 +0200 |
| commit | f152d42f66feb4120a0c231eb941a367a3bf2271 (patch) | |
| tree | 8b241ef210cb4916316502dd4c2d8959cc3d8346 /wrappers/python/eduvpn_common/error.py | |
| parent | d6b10d67deb142ad7dedeee9eebb66079b69e328 (diff) | |
Python: Add docstrings
Diffstat (limited to 'wrappers/python/eduvpn_common/error.py')
| -rw-r--r-- | wrappers/python/eduvpn_common/error.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/wrappers/python/eduvpn_common/error.py b/wrappers/python/eduvpn_common/error.py index a5b59b4..626d9a2 100644 --- a/wrappers/python/eduvpn_common/error.py +++ b/wrappers/python/eduvpn_common/error.py @@ -2,6 +2,7 @@ from enum import Enum class ErrorLevel(Enum): + """The error level enum""" ERR_OTHER = 0 ERR_INFO = 1 ERR_WARNING = 2 @@ -9,6 +10,12 @@ class ErrorLevel(Enum): class WrappedError(Exception): + """An exception returned by the Go library + + :param: traceback: str: The traceback of the error including newlines + :param: cause: str: The cause of the error as a message + :param: level: ErrorLevel: The level of the error + """ def __init__(self, traceback: str, cause: str, level: ErrorLevel): super(WrappedError, self).__init__(cause) self.traceback = traceback |
