pub enum CoreError {
Store(StoreError),
Printer(PrinterError),
Vision(VisionError),
Supervisor(SupervisorError),
NoSuchPrint {
print_id: PrintId,
},
Unrepresentable {
detail: String,
},
}Expand description
Why core could not do what it was asked.
A port’s own error is carried rather than flattened into a message, because a caller that has somewhere to put a failure needs to know which port failed and how — the store’s initial event append in particular, which is the one failure core cannot record anywhere and so answers to its caller.
Variants§
Store(StoreError)
The store failed, in its own words.
Printer(PrinterError)
The printer failed, in its own words.
Vision(VisionError)
The vision port failed, in its own words.
Supervisor(SupervisorError)
The supervising agent’s harness failed, in its own words.
NoSuchPrint
There is no print by that identifier.
Unrepresentable
A value this crate computed is not representable: an instant past what a timestamp holds, or an event payload that would not render as JSON.
Trait Implementations§
impl Eq for CoreError
Source§impl Error for CoreError
impl Error for CoreError
1.30.0 · 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()
Source§impl From<StoreError> for CoreError
impl From<StoreError> for CoreError
Source§fn from(error: StoreError) -> Self
fn from(error: StoreError) -> Self
Converts to this type from the input type.
impl StructuralPartialEq for CoreError
Auto Trait Implementations§
impl Forget for CoreError
impl Freeze for CoreError
impl Move for CoreError
impl RefUnwindSafe for CoreError
impl Send for CoreError
impl Sync for CoreError
impl Unpin for CoreError
impl UnsafeUnpin for CoreError
impl UnwindSafe for CoreError
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