#[non_exhaustive]pub enum Error {
Show 17 variants
Io(Arc<Error>),
MoqNet(Error),
Directive(Arc<ParseError>),
SetSubscriber(Arc<TryInitError>),
Logcat(Arc<Error>),
NoBackend(&'static str),
ConnectFailed,
Connect(ConnectError),
TransportRace {
quic: Arc<Error>,
websocket: Arc<Error>,
},
MtlsUnsupported,
InvalidStatusCode,
Reconnect(String),
Tls(Arc<Error>),
Quinn(Arc<Error>),
WebSocket(Arc<Error>),
Tcp(Arc<Error>),
Unix(Arc<Error>),
}Expand description
Errors produced while configuring or establishing native MoQ connections.
Backend-specific failures live in per-backend error types (crate::tls::Error,
the per-backend Error types, etc.). They’re wrapped in Arc here so the aggregate
stays Clone even though the underlying transport/IO errors are not.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Io(Arc<Error>)
Reading or writing a socket, certificate, or key file failed.
MoqNet(Error)
The MoQ session itself failed, after the transport was established.
Directive(Arc<ParseError>)
The log filter string (ex. RUST_LOG) isn’t a valid tracing directive.
SetSubscriber(Arc<TryInitError>)
Logging was initialized twice, or something else already claimed the global subscriber.
Logcat(Arc<Error>)
Logging couldn’t attach to Android’s logcat.
NoBackend(&'static str)
No backend feature is compiled in that can serve this URL. The string names the features to enable.
ConnectFailed
Every backend we tried gave up without reporting why.
Connect(ConnectError)
The server rejected the connection with an auth status. See crate::ConnectError.
TransportRace
Both halves of the QUIC/WebSocket race failed, so neither error alone tells the story.
Fields
MtlsUnsupported
A client certificate was configured, but this QUIC backend can’t do mTLS.
InvalidStatusCode
The server’s WebTransport response carried a status outside the valid HTTP range.
Reconnect(String)
Reconnecting gave up, usually after the backoff timeout expired. The string has the details.
Tls(Arc<Error>)
Loading certificates or building the TLS config failed.
Quinn(Arc<Error>)
The Quinn backend failed.
WebSocket(Arc<Error>)
The WebSocket fallback transport failed.
Tcp(Arc<Error>)
The TCP (qmux) transport failed.
Unix(Arc<Error>)
The Unix socket transport failed.
Implementations§
Source§impl Error
impl Error
Sourcepub fn connect_error(&self) -> Option<ConnectError>
pub fn connect_error(&self) -> Option<ConnectError>
The auth rejection behind this error, digging through backend and race variants.
Trait Implementations§
Source§impl Error for Error
impl Error for Error
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()