blob: c5e8e160c5c86de6df7107fe02765fa252fbe9ca (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
"""
Part of the BlackStar filesystem (bsfs) module.
A copy of the license is provided with the project.
Author: Matthias Baumgartner, 2022
"""
# imports
import typing
# exports
__all__: typing.Sequence[str] = (
)
## code ##
class _BSFSError(Exception):
"""Generic bsfs error."""
class SchemaError(_BSFSError):
"""Generic schema errios."""
class ConsistencyError(SchemaError):
"""A requested operation is inconsistent with the schema."""
class InstanceError(SchemaError):
"""An instance affected by some operation is inconsistent with the schema."""
class PermissionDeniedError(_BSFSError):
"""An operation was aborted due to access control restrictions."""
class ProgrammingError(_BSFSError):
"""An assertion-like error that indicates a code-base issue."""
class UnreachableError(ProgrammingError):
"""Bravo, you've reached a point in code that should logically not be reachable."""
class ConfigError(_BSFSError):
"""User config issue."""
## EOF ##
|