pub enum Error {
RuntimeNotFound {
runtime: &'static str,
tool: &'static str,
},
CommandFailedToRun {
command: String,
source: Error,
},
CommandFailed {
command: String,
status: String,
stderr: String,
},
UnexpectedOutput {
command: String,
message: String,
},
InvalidPid {
pid: String,
runtime: &'static str,
container: String,
source: ParseIntError,
},
NotRunning(String),
ContainerNotFound {
container: String,
message: String,
},
Io {
path: PathBuf,
source: Error,
},
InvalidProcessId(String, ParseIntError),
NoSuchProcess(RawPid),
NoRuntimeMatched {
container: String,
tried: String,
},
}Expand description
Errors that can occur while resolving a container name to a PID.
Variants§
RuntimeNotFound
The container runtime CLI needed for this backend is not installed.
CommandFailedToRun
Spawning the runtime CLI failed.
CommandFailed
The runtime CLI ran but exited with an error.
UnexpectedOutput
The runtime CLI produced output we could not parse.
InvalidPid
The runtime reported a PID that is not a number.
NotRunning(String)
The container exists but is not running.
ContainerNotFound
No container matched the given name/ID for this backend.
Io
Reading a file or directory failed.
InvalidProcessId(String, ParseIntError)
The given container ID is not a valid process ID.
NoSuchProcess(RawPid)
No process with the given PID exists.
NoRuntimeMatched
None of the tried container runtimes could resolve the container.
Trait Implementations§
Source§impl Error for Error
impl Error for Error
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 Error
impl !UnwindSafe for Error
impl Freeze for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnsafeUnpin for Error
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