pub enum WitnessError {
Network(String),
Duplicity(DuplicityEvidence),
Rejected {
reason: String,
},
Timeout(u64),
InvalidSignature {
witness_id: String,
},
InsufficientReceipts {
got: usize,
required: usize,
},
SaidMismatch {
expected: Said,
got: Said,
},
Storage(String),
Serialization(String),
}Expand description
Errors that can occur during witness operations.
These errors cover the full range of failure modes for async witness interactions, from network issues to security violations.
Variants§
Network(String)
Network error communicating with witness.
Duplicity(DuplicityEvidence)
Duplicity detected - the controller presented different events.
This is a security violation indicating a potential split-view attack.
Rejected
The witness rejected the event.
This can happen if the event is malformed, the witness doesn’t track this identity, or the event fails validation.
Timeout(u64)
Operation timed out.
InvalidSignature
Invalid receipt signature.
InsufficientReceipts
Insufficient receipts to meet threshold.
SaidMismatch
Receipt is for wrong event.
Storage(String)
Storage error.
Serialization(String)
Serialization error.
Trait Implementations§
Source§impl Debug for WitnessError
impl Debug for WitnessError
Source§impl Display for WitnessError
impl Display for WitnessError
Source§impl Error for WitnessError
impl Error for WitnessError
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()
Auto Trait Implementations§
impl Freeze for WitnessError
impl RefUnwindSafe for WitnessError
impl Send for WitnessError
impl Sync for WitnessError
impl Unpin for WitnessError
impl UnsafeUnpin for WitnessError
impl UnwindSafe for WitnessError
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