pub enum CliError {
Usage(String),
StartIcp(Error),
Icp {
status: String,
message: String,
},
Encode {
method: &'static str,
source: Error,
},
Decode {
method: &'static str,
source: Error,
},
RawReply(&'static str),
Canister {
method: &'static str,
error: String,
},
Json(Error),
Io(Error),
PaginationStalled(String),
PaginationLimit(usize),
}Expand description
Failure reported by CLI parsing, the ICP process boundary, or the typed canister protocol.
Variants§
Usage(String)
Command-line arguments did not describe a valid operation.
StartIcp(Error)
The ICP CLI process could not be started.
Icp
The ICP CLI process reported a failed call.
Fields
Encode
Typed Candid argument encoding failed before the process was started.
Decode
The canister reply was not valid for the shared interface type.
Fields
RawReply(&'static str)
The ICP CLI returned something other than one bounded hexadecimal reply.
Canister
A typed application error was returned by the canister.
Fields
Json(Error)
JSON rendering failed.
Io(Error)
Writing the final report failed.
PaginationStalled(String)
A canister returned a continuation that had already been observed.
PaginationLimit(usize)
Automatic pagination reached its operator-provided safety bound.
Implementations§
Trait Implementations§
Source§impl Error for CliError
impl Error for CliError
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 CliError
impl !UnwindSafe for CliError
impl Freeze for CliError
impl Send for CliError
impl Sync for CliError
impl Unpin for CliError
impl UnsafeUnpin for CliError
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