Module rok4.exceptions
Classes
class FormatError (expected_format, content, issue)
-
Exception raised when a format is expected but not respected
Expand source code
class FormatError(Exception): """ Exception raised when a format is expected but not respected """ def __init__(self, expected_format, content, issue): self.expected_format = expected_format self.content = content self.issue = issue super().__init__(f"Expected format {expected_format} to read '{content}' : {issue}")
Ancestors
- builtins.Exception
- builtins.BaseException
class MissingAttributeError (path, missing)
-
Exception raised when an attribute is missing in a file
Expand source code
class MissingAttributeError(Exception): """ Exception raised when an attribute is missing in a file """ def __init__(self, path, missing): self.path = path self.missing = missing super().__init__(f"Missing attribute {missing} in '{path}'")
Ancestors
- builtins.Exception
- builtins.BaseException
class MissingEnvironmentError (missing)
-
Exception raised when a needed environment variable is not defined
Expand source code
class MissingEnvironmentError(Exception): """ Exception raised when a needed environment variable is not defined """ def __init__(self, missing): self.missing = missing super().__init__(f"Missing environment variable {missing}")
Ancestors
- builtins.Exception
- builtins.BaseException
class StorageError (type, issue)
-
Exception raised when an issue occured when using a storage
Expand source code
class StorageError(Exception): """ Exception raised when an issue occured when using a storage """ def __init__(self, type, issue): self.type = type self.issue = issue super().__init__(f"Issue occured using a {type} storage : {issue}")
Ancestors
- builtins.Exception
- builtins.BaseException