src/rdflib/contrib/rdf4j/exceptions.py
1"""RDF4J exceptions."""
2
3
4class RDF4JError(Exception):
5 """Base class for RDF4J exceptions."""
6
7
8class RepositoryError(RDF4JError):
9 """Raised when interactions on a repository result in an error."""
10
11
12class RepositoryResponseFormatError(RepositoryError):
13 """Raised when the repository response format is invalid."""
14
15
16class RepositoryNotFoundError(RepositoryError):
17 """Raised when the repository is not found."""
18
19
20class RepositoryNotHealthyError(RepositoryError):
21 """Raised when the repository is not healthy."""
22
23
24class RepositoryAlreadyExistsError(RepositoryError):
25 """Raised when the repository already exists."""
26
27
28class RDF4JUnsupportedProtocolError(RDF4JError):
29 """Raised when the server does not support the protocol version."""
30
31
32class RDFLibParserError(RDF4JError):
33 """Raised when there is an error parsing the RDF document."""
34
35
36class RepositoryTransactionError(RDF4JError):
37 """Raised when there is an error with the transaction."""
38
39
40class TransactionClosedError(RepositoryTransactionError):
41 """Raised when the transaction has been closed."""
42
43
44class TransactionPingError(RepositoryTransactionError):
45 """Raised when there is an error pinging the transaction."""
46
47
48class TransactionCommitError(RepositoryTransactionError):
49 """Raised when there is an error committing the transaction."""
50
51
52class TransactionRollbackError(RepositoryTransactionError):
53 """Raised when there is an error rolling back the transaction."""