Source code for hypergraphx.exceptions

[docs] class HypergraphxError(Exception): """Base exception for hypergraphx errors."""
[docs] class MissingNodeError(ValueError, HypergraphxError): """Raised when a node is missing from a hypergraph."""
[docs] class MissingEdgeError(ValueError, HypergraphxError): """Raised when an edge is missing from a hypergraph."""
[docs] class InvalidFormatError(ValueError, HypergraphxError): """Raised when an invalid format is provided."""
[docs] class InvalidFileTypeError(ValueError, HypergraphxError): """Raised when an unsupported file extension is provided."""
[docs] class ReadwriteError(RuntimeError, HypergraphxError): """Raised when read/write operations fail."""
[docs] class InvalidParameterError(ValueError, HypergraphxError): """Raised when invalid or conflicting parameters are provided."""