zeph_core/subagent/
error.rs1#[derive(Debug, thiserror::Error)]
5pub enum SubAgentError {
6 #[error("parse error in {path}: {reason}")]
7 Parse { path: String, reason: String },
8
9 #[error("invalid definition: {0}")]
10 Invalid(String),
11
12 #[error("agent not found: {0}")]
13 NotFound(String),
14
15 #[error("spawn failed: {0}")]
16 Spawn(String),
17
18 #[error("cancelled")]
19 Cancelled,
20
21 #[error("invalid command: {0}")]
22 InvalidCommand(String),
23
24 #[error("transcript error: {0}")]
25 Transcript(String),
26
27 #[error("ambiguous id prefix '{0}': matches {1} agents")]
28 AmbiguousId(String, usize),
29
30 #[error("agent '{0}' is still running; cancel it first or wait for completion")]
31 StillRunning(String),
32
33 #[error("memory error for agent '{name}': {reason}")]
34 Memory { name: String, reason: String },
35
36 #[error("I/O error at {path}: {reason}")]
37 Io { path: String, reason: String },
38
39 #[error(transparent)]
40 Other(#[from] anyhow::Error),
41}