pub enum TerminalError {
Show 18 variants
InvalidGraph(String),
NodeNotFound(String),
MissingEdge {
from: String,
to: String,
},
NodeExecutionFailed {
node: String,
source: Box<dyn Error + Send + Sync>,
},
StepsExceeded {
limit: usize,
},
LoopLimitExceeded {
limit: usize,
},
BarrierTimeout {
node: String,
timeout: Duration,
},
BarrierCancelled {
node: String,
},
Unrouted {
node: String,
attempted_conditions: Vec<ConditionEval>,
},
StateError(String),
CheckpointSaveFailed {
error: String,
},
RestoreUnsupported {
node: String,
kind: String,
},
RestoreNotLatest {
checkpoint: String,
latest: String,
},
RestoreUnsupportedFormat {
actual: u32,
expected: u32,
},
RestoreGraphMismatch {
expected: u64,
actual: u64,
},
TraceNotFresh {
trace: String,
latest: String,
},
CheckpointLoadFailed {
error: String,
},
RestoreFailed {
reason: String,
},
}Expand description
终止错误 — Graph 执行不可恢复地停止。
Variants§
InvalidGraph(String)
图结构无效(构建时校验遗漏的运行时问题)
NodeNotFound(String)
节点不存在
MissingEdge
Goto 目标缺少对应的边
NodeExecutionFailed
节点执行失败(不可恢复)
StepsExceeded
全局步数超限(运行时熔断)
LoopLimitExceeded
循环超限
BarrierTimeout
Barrier 超时
BarrierCancelled
Barrier 被取消
Unrouted
无匹配边 — 没有任何 outgoing edge 满足条件,且无 fallback
StateError(String)
State 操作错误
CheckpointSaveFailed
检查点同步保存失败 — 执行在该边界停止
RestoreUnsupported
持久化/恢复入口遇到不支持的图结构(Parallel/Subgraph/Barrier)
RestoreNotLatest
传入的检查点不是该 trace 的最新检查点 — 拒绝续写原 trace(避免历史分叉)
RestoreUnsupportedFormat
检查点格式版本不支持(legacy 格式)
RestoreGraphMismatch
graph_hash 不匹配(图结构已变更)
TraceNotFresh
trace 已有检查点 — 首次执行入口要求 trace 新鲜
CheckpointLoadFailed
检查点加载失败(存储读取错误 — 存储故障语义,非恢复校验失败)
RestoreFailed
恢复前置条件失败(其他未结构化原因)
Trait Implementations§
Source§impl Debug for TerminalError
impl Debug for TerminalError
Source§impl Display for TerminalError
impl Display for TerminalError
Source§impl Error for TerminalError
impl Error for TerminalError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations§
impl !RefUnwindSafe for TerminalError
impl !UnwindSafe for TerminalError
impl Freeze for TerminalError
impl Send for TerminalError
impl Sync for TerminalError
impl Unpin for TerminalError
impl UnsafeUnpin for TerminalError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more