pub enum RuntimeError {
Replay(ReplayError),
Store(StoreError),
Model(Error),
RequestEncode(Error),
RecordedResponseDecode(Error),
RunAlreadyStarted {
run_id: RunId,
},
UnknownRun {
run_id: RunId,
},
NotParked {
run_id: RunId,
status: String,
},
ResumeInputRejected(String),
InvalidLabels(String),
NotReconcilable {
run_id: RunId,
status: String,
},
AlreadyTerminal {
run_id: RunId,
status: String,
},
}Expand description
What can go wrong while driving a run.
Variants§
Replay(ReplayError)
The replay layer refused to continue: divergence, a malformed log, or a dangling write intent that needs human reconciliation.
Store(StoreError)
The event store failed to persist or read an event.
Model(Error)
A live model call failed after the client’s own retries. The run’s log is intact (the intent, if any, is recorded), so the run can be recovered later; the model intent will be re-issued safely.
RequestEncode(Error)
A model request could not be serialized to JSON for hashing.
RecordedResponseDecode(Error)
A recorded model response could not be decoded back into a typed response. This means the log holds something this build cannot read, which is a storage or versioning fault, not orchestration divergence.
RunAlreadyStarted
start was called for a run id that already has recorded history.
UnknownRun
The named run has no recorded history at all.
NotParked
resume was called on a run whose log does not end at a suspension
or budget crossing.
Fields
ResumeInputRejected(String)
The resume input did not satisfy the recorded suspension schema (or, for a budget crossing, the budget-extension shape).
InvalidLabels(String)
The labels a run is about to be created with violate the sanity
bounds (too many, or a key/value over its length cap). See
crate::validate_labels. Surfaces only on a genuinely fresh
begin; a replayed run never re-checks the labels it already
recorded.
NotReconcilable
resolve was called on a run that is not awaiting reconciliation. The
hand-recorded completion is only ever appended to a run whose log ends
at a dangling write intent; every other state is a caller mistake.
Fields
AlreadyTerminal
abandon was called on a run that already reached a terminal event
(completed, failed, or previously abandoned). A terminal run is already
at rest; there is nothing left to retire, so the operator action is
refused rather than appending a second terminal.
Trait Implementations§
Source§impl Debug for RuntimeError
impl Debug for RuntimeError
Source§impl Display for RuntimeError
impl Display for RuntimeError
Source§impl Error for RuntimeError
impl Error for RuntimeError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()