pub enum DeribitWsError {
Show 15 variants
NotConnected,
Transport(String),
Send(String),
AdmissionClosed,
CanceledBeforeSend,
Encode(String),
TransportSend(SendError),
Json(String),
Authentication(String),
ClientError(String),
ParsingError(String),
DeribitError {
code: i64,
message: String,
},
TungsteniteError(String),
Subscribe(String),
Timeout(String),
}Expand description
Error types for the Deribit WebSocket client.
Variants§
NotConnected
Client is not connected.
Transport(String)
Transport-level error during WebSocket communication.
Send(String)
Failed to send message over WebSocket.
AdmissionClosed
The handler command channel was closed before the order command was queued.
CanceledBeforeSend
The handler was stopping, so the order command was not written.
Encode(String)
Order-command encoding failed before a write started.
TransportSend(SendError)
Order-command send failure. WriteTimeout and BrokenPipe can follow a started write;
other variants fail before the write.
Json(String)
JSON serialization/deserialization error.
Authentication(String)
Authentication failed.
ClientError(String)
Generic client error.
ParsingError(String)
Parsing error during message processing.
DeribitError
Error returned by Deribit API (JSON-RPC error response).
TungsteniteError(String)
WebSocket transport error from tungstenite.
Subscribe(String)
Subscription rejected by server.
Timeout(String)
Request timeout.
Trait Implementations§
Source§impl Clone for DeribitWsError
impl Clone for DeribitWsError
Source§impl Debug for DeribitWsError
impl Debug for DeribitWsError
Source§impl Display for DeribitWsError
impl Display for DeribitWsError
Source§impl Error for DeribitWsError
impl Error for DeribitWsError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl From<Error> for DeribitWsError
impl From<Error> for DeribitWsError
Source§impl From<Error> for DeribitWsError
impl From<Error> for DeribitWsError
Auto Trait Implementations§
impl Freeze for DeribitWsError
impl RefUnwindSafe for DeribitWsError
impl Send for DeribitWsError
impl Sync for DeribitWsError
impl Unpin for DeribitWsError
impl UnsafeUnpin for DeribitWsError
impl UnwindSafe for DeribitWsError
Blanket Implementations§
impl<T> Allocation for T
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more