nrel.hive.util.exception

Module Contents

Functions

report_error(→ Dict)

helper to enforce standardization of observed errors reported during simulation run

nrel.hive.util.exception.report_error(error: Exception) Dict[source]

helper to enforce standardization of observed errors reported during simulation run

Parameters:

error – the error that occurred during simulation

Returns:

packaged as a report

exception nrel.hive.util.exception.TimeParseError(msg)[source]

Bases: Exception

raised when time parsing fails

__str__()[source]

Return str(self).

exception nrel.hive.util.exception.StateTransitionError(msg: str, this_state_name: str | None = None, next_state_name: str | None = None)[source]

Bases: Exception

calls out a breach in the simulation’s physics observed when a state transition’s invariants are not met.

__str__()[source]

Return str(self).

exception nrel.hive.util.exception.StateOfChargeError(soc)[source]

Bases: Exception

state of charge must exist in the range [0, 1]

__str__()[source]

Return str(self).

exception nrel.hive.util.exception.RouteStepError(msg)[source]

Bases: Exception

errors related to stepping forward along a route

__str__()[source]

Return str(self).

exception nrel.hive.util.exception.SimulationStateError(msg)[source]

Bases: Exception

errors related to SimulationState operations

__str__()[source]

Return str(self).

exception nrel.hive.util.exception.UnitError(msg)[source]

Bases: Exception

errors related to units

__str__()[source]

Return str(self).

exception nrel.hive.util.exception.EntityError(msg)[source]

Bases: Exception

errors related to methods on entities such as vehicles or stations.

__str__()[source]

Return str(self).

exception nrel.hive.util.exception.H3Error(msg)[source]

Bases: Exception

errors related to H3 operations

__str__()[source]

Return str(self).

exception nrel.hive.util.exception.CombinedException(errors: Tuple[Exception, Ellipsis])[source]

Bases: Exception

a bundle of errors which can be raised as a single Exception

__str__()[source]

Return str(self).

exception nrel.hive.util.exception.InstructionError(msg)[source]

Bases: Exception

reports that an instruction was erroneous

__str__()[source]

Return str(self).