#[non_exhaustive]pub enum PeError {
Show 54 variants
GraphRecursion {
limit: u32,
},
GraphInterrupt {
reason: String,
},
NodeInterrupt {
reason: String,
},
InvalidUpdate {
details: String,
},
EmptyChannel {
channel: String,
},
GraphValue {
details: String,
},
UnreachableNode {
node: String,
},
EmptyInput,
MultipleSubgraphs {
details: String,
},
AgentNotFound {
agent_id: String,
},
AgentUnreachable {
agent_id: String,
reason: String,
},
HandoffCycle {
path: String,
},
MaxHandoffs {
max: u32,
},
PermissionDenied {
action: String,
},
ToolDenied {
tool: String,
reason: String,
},
CommunicationBlocked {
target: String,
},
ApprovalDenied {
action: String,
reason: String,
},
ApprovalRequired {
action: String,
},
GuardrailViolation {
guardrail: String,
details: String,
},
WriteGovernanceViolation {
destination: String,
reason: String,
},
InspectionDenied {
root: String,
reason: String,
},
InspectionFailed {
path: String,
reason: String,
},
ToolExecution {
tool: String,
reason: String,
},
ToolNotFound {
tool: String,
},
ToolAlreadyRegistered {
tool: String,
},
LlmProvider {
details: String,
},
LlmAuth {
details: String,
},
LlmRateLimit {
details: String,
},
LlmEmpty,
MockProviderExhausted,
EmbeddingDimension {
expected: usize,
actual: usize,
},
StructuredOutput {
details: String,
},
Storage {
details: String,
},
CheckpointNotFound {
thread_id: String,
},
BusError {
details: String,
},
NegotiationFailed {
reason: String,
},
NegotiationInterrupted {
reason: String,
},
Timeout {
seconds: f64,
},
BudgetExceeded {
budget_type: String,
},
InvalidAgent(String),
ManifestLoad(String),
ManifestParse(String),
CyclicDelegation {
chain: Vec<String>,
attempted: String,
},
ResumePointMismatch {
expected: String,
actual: String,
},
MissingHumanInput,
MatrixDimensionMismatch {
expected: usize,
actual: usize,
},
NodeNotFound {
node: String,
},
ConstraintViolation {
constraint: String,
detail: String,
},
CompositionError {
reason: String,
},
InvalidPayload {
reason: String,
},
CognitiveBudgetExhausted {
agent_id: String,
tokens_used: u32,
limit: u32,
},
CognitiveSignalVeto {
agent_id: String,
lobe: String,
reason: String,
},
LobeActivationFailed {
lobe: String,
reason: String,
},
Internal {
details: String,
},
}Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
GraphRecursion
GraphInterrupt
NodeInterrupt
InvalidUpdate
EmptyChannel
GraphValue
UnreachableNode
EmptyInput
MultipleSubgraphs
AgentNotFound
AgentUnreachable
HandoffCycle
MaxHandoffs
PermissionDenied
ToolDenied
CommunicationBlocked
ApprovalDenied
ApprovalRequired
GuardrailViolation
WriteGovernanceViolation
InspectionDenied
InspectionFailed
ToolExecution
ToolNotFound
ToolAlreadyRegistered
LlmProvider
LlmAuth
Authentication/authorization failed (HTTP 401/403). NOT retryable — a bad API key will never succeed on retry.
LlmRateLimit
Rate limited by the provider (HTTP 429). Retryable with backoff.
LlmEmpty
MockProviderExhausted
EmbeddingDimension
StructuredOutput
Storage
CheckpointNotFound
BusError
NegotiationFailed
NegotiationInterrupted
Timeout
BudgetExceeded
InvalidAgent(String)
ManifestLoad(String)
ManifestParse(String)
CyclicDelegation
ResumePointMismatch
Resume point mismatch between checkpoint and command.
Fields
MissingHumanInput
Node expected human input on resume but none was provided.
MatrixDimensionMismatch
NodeNotFound
ConstraintViolation
CompositionError
InvalidPayload
CognitiveBudgetExhausted
Cognitive budget exhausted — lobes consumed all allocated tokens/time.
CognitiveSignalVeto
A lobe vetoed the output — blocks execution.
LobeActivationFailed
A lobe failed to activate or process.
This is a structural failure (not transient). Transient failures
(e.g., model unavailable) should be reported as PeError::LlmProvider or
PeError::Timeout by the lobe itself before returning this error.
Internal
Implementations§
Source§impl PeError
impl PeError
Sourcepub fn is_retryable(&self) -> bool
pub fn is_retryable(&self) -> bool
Whether this error is retryable by a retry policy.
Transient failures (timeouts, LLM provider errors, tool execution errors) are retryable. Structural errors (invalid graph, permission denied, missing input) are not.
Sourcepub fn is_transient(&self) -> bool
pub fn is_transient(&self) -> bool
Whether this error represents a transient condition that may resolve later.
Transient errors are temporary — the same operation might succeed on retry or after a delay. Permanent errors indicate structural problems that will never resolve without code/config changes.
is_retryable() is a subset of is_transient(): all retryable errors are
transient, but some transient errors (like BusError) may not benefit from
immediate retry.
Trait Implementations§
Source§impl Error for PeError
impl Error for PeError
1.30.0 · 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()