pub enum SessionError {
NotFound(SessionId),
InvalidState {
session_id: SessionId,
current_state: SessionState,
expected: &'static str,
},
ThresholdNotMet {
have: usize,
need: u32,
},
DuplicateSubmission {
signer: SignerId,
session: SessionId,
},
Expired(SessionId),
UnauthorizedSigner(SignerId),
}Expand description
Session errors.
Variants§
NotFound(SessionId)
Session not found.
InvalidState
Session in wrong state.
Fields
§
current_state: SessionStateCurrent state.
ThresholdNotMet
Threshold not met.
DuplicateSubmission
Signer already submitted.
Expired(SessionId)
Unlock window expired.
Unauthorized signer.
Trait Implementations§
Source§impl Debug for SessionError
impl Debug for SessionError
Source§impl Display for SessionError
impl Display for SessionError
Source§impl Error for SessionError
impl Error for SessionError
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 SessionError
impl RefUnwindSafe for SessionError
impl Send for SessionError
impl Sync for SessionError
impl Unpin for SessionError
impl UnsafeUnpin for SessionError
impl UnwindSafe for SessionError
Blanket Implementations§
§impl<T> AsErrorSource for Twhere
T: Error + 'static,
impl<T> AsErrorSource for Twhere
T: Error + 'static,
§fn as_error_source(&self) -> &(dyn Error + 'static)
fn as_error_source(&self) -> &(dyn Error + 'static)
For maximum effectiveness, this needs to be called as a method
to benefit from Rust’s automatic dereferencing of method
receivers.
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