simpy.exceptions — Exception types used by SimPy¶
SimPy specific exeptions.
-
exception
simpy.exceptions.SimPyException¶ Base class for all SimPy specific exceptions.
-
exception
simpy.exceptions.Interrupt(cause)¶ Exception thrown into a process if it is interrupted (see
interrupt()).causeprovides the reason for the interrupt, if any.If a process is interrupted concurrently, all interrupts will be thrown into the process in the same order as they occurred.
-
cause¶ The cause of the interrupt or
Noneif no cause was provided.
-
-
exception
simpy.exceptions.StopProcess(value)¶ Raised to stop a SimPy process (similar to
StopIteration).In Python 2, a
return valueinside generator functions is not allowed. The fall-back was raisingStopIteration(value)instead. However, this is deprecated now, so we need a custom exception type for this.-
value¶ The process’ return value.
-