maptor.exceptions#
Exception classes for error handling.
- exception maptor.exceptions.MAPTORBaseError(message, context=None)[source]#
Bases:
Exception
Base class for all MAPTOR-specific errors.
All MAPTOR exceptions inherit from this class, allowing users to catch any MAPTOR-specific error with a single except clause.
- Args:
message: The error message describing what went wrong context: Optional additional context about where the error occurred
- exception maptor.exceptions.ConfigurationError(message, context=None)[source]#
Bases:
MAPTORBaseError
Raised when there is an invalid or incomplete MAPTOR configuration.
This exception indicates that the user has provided invalid parameters, missing required configuration, or conflicting settings that prevent the problem from being solved.
- Examples:
Invalid polynomial degrees
Missing dynamics or objective function
Incompatible constraint specifications
Invalid mesh configuration
- exception maptor.exceptions.DataIntegrityError(message, context=None)[source]#
Bases:
MAPTORBaseError
Raised when internal data corruption or inconsistency is detected.
This exception indicates an internal MAPTOR error where data structures have become corrupted or inconsistent. This typically represents a bug in MAPTOR rather than user error.
- Examples:
NaN or infinite values in computed results
Mismatched array dimensions in internal calculations
Corrupted solution data structures
- exception maptor.exceptions.SolutionExtractionError(message, context=None)[source]#
Bases:
MAPTORBaseError
Raised when solution data cannot be extracted from the optimization result.
This exception occurs when MAPTOR fails to process the raw solver output into the user-friendly Solution format, typically due to unexpected solver behavior or corrupted optimization results.
- exception maptor.exceptions.InterpolationError(message, context=None)[source]#
Bases:
MAPTORBaseError
Raised when adaptive mesh interpolation operations fail.
This exception occurs during adaptive mesh refinement when MAPTOR cannot successfully interpolate solution data between different mesh configurations, typically due to numerical issues or corrupted trajectory data.