udaan.core.exceptions module

Custom exceptions for Udaan library.

Provides a hierarchy of exceptions for better error handling and debugging. All Udaan-specific exceptions inherit from UdaanError.

exception udaan.core.exceptions.ConfigurationError[source]

Bases: UdaanError

Raised when configuration parameters are invalid.

Examples

  • Negative mass

  • Non-symmetric inertia matrix

  • Invalid control gains

exception udaan.core.exceptions.ControllerNotInitializedError[source]

Bases: UdaanError

Raised when a controller is used before proper initialization.

Some controllers (like L1 adaptive) require an initialization step before they can compute control outputs.

exception udaan.core.exceptions.ManifoldTypeError[source]

Bases: UdaanError, TypeError

Raised when a manifold operation receives an incompatible type.

Examples

  • SO3 + ndarray instead of SO3 + TSO3

  • S2 - ndarray instead of S2 - S2

exception udaan.core.exceptions.PhysicsBackendError[source]

Bases: UdaanError

Raised when there’s an issue with the physics backend.

Examples

  • MuJoCo model loading failure

  • PyBullet connection error

  • Missing physics assets

__init__(backend, message)[source]
exception udaan.core.exceptions.SimulationError[source]

Bases: UdaanError

Raised when an error occurs during simulation execution.

Examples

  • Physics engine failure

  • Invalid state reached

  • Timeout exceeded

exception udaan.core.exceptions.SingularityError[source]

Bases: UdaanError

Raised when a numerical singularity is encountered.

This typically occurs in geometric computations when:
  • Normalizing a near-zero vector

  • Computing logarithm at 180-degree rotation

  • Dividing by near-zero thrust

operation

Name of the operation that encountered the singularity.

value

The problematic value that caused the singularity.

__init__(operation, value)[source]
exception udaan.core.exceptions.UdaanError[source]

Bases: Exception

Base exception for all Udaan library errors.

Catch this to handle any Udaan-specific exception.