pub enum Outcome {
Running,
Succeeded,
Failed,
TimedOut,
Halted,
Interrupted,
}Expand description
How a run ended.
Running is here rather than in a separate “live” type so that one query answers both “what
is happening now” and “what happened last week”. A dashboard that had to stitch two sources
together would show them disagreeing during the moment a run finishes.
Variants§
Running
Still going.
Succeeded
Exited successfully.
Failed
Exited non-zero, or the runner reported failure.
TimedOut
Hit timeout_sec and was killed.
Halted
Stopped because a rail refused it: Hops, Fuel, the run cap or the Reserve.
Interrupted
Was alive when the Tower went away. See the recovery model.
Implementations§
Source§impl Outcome
impl Outcome
Sourcepub fn is_success(self) -> bool
pub fn is_success(self) -> bool
Returns true when the run finished the way it was supposed to.
Sourcepub fn is_failure(self) -> bool
pub fn is_failure(self) -> bool
Returns true when the run ended badly enough to be worth a human’s attention.
Outcome::Halted is deliberately excluded. A rail stopping work is the system doing its
job, and colouring it like a crash would train people to ignore the colour.