1use thiserror::Error;
4
5#[derive(Error, Debug)]
7pub enum SandboxError {
8 #[error("Connection failed: {0}")]
10 ConnectionFailed(String),
11
12 #[error("Sandbox not ready: {0}")]
14 NotReady(String),
15
16 #[error("Sandbox not available: {0}")]
18 NotAvailable(String),
19
20 #[error("Configuration error: {0}")]
22 ConfigError(String),
23
24 #[error("Failed to create sandbox: {0}")]
26 CreateFailed(String),
27
28 #[error("Failed to start sandbox: {0}")]
30 StartFailed(String),
31
32 #[error("Start error: {0}")]
34 StartError(String),
35
36 #[error("Execution timed out")]
38 Timeout,
39
40 #[error("Execution failed: {0}")]
42 ExecutionFailed(String),
43
44 #[error("IO error: {0}")]
46 IoError(#[from] std::io::Error),
47
48 #[error("Failed to stop sandbox: {0}")]
50 StopFailed(String),
51}