#[non_exhaustive]pub enum XetError {
Show 16 variants
KeyboardInterrupt,
UserCancelled(String),
PreviousTaskError(String),
TaskError(String),
AlreadyCompleted,
InvalidTaskID(UniqueID),
Authentication(String),
Network(String),
Timeout(String),
NotFound(String),
DataIntegrity(String),
Configuration(String),
Io(String),
Cancelled(String),
Internal(String),
WrongRuntimeMode(String),
}Expand description
Unified error type for the Xet public API.
Variants are grouped into user-facing categories that map naturally to Python exception types, plus session-lifecycle states that the internal code can match on.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
KeyboardInterrupt
SIGINT / runtime shutdown.
UserCancelled(String)
Explicit user abort (session, commit, group, or stream level).
PreviousTaskError(String)
A previous operation on this task failed; carries the stored error description.
TaskError(String)
Task-level error captured from a background upload/download handle.
AlreadyCompleted
The operation has already completed, is already finalizing, or was already committed/finished.
InvalidTaskID(UniqueID)
A task ID that doesn’t correspond to any queued file.
Authentication(String)
Token refresh or credential failures.
Network(String)
Network-level failures: DNS, HTTP 5xx, connection reset, etc.
Timeout(String)
A network request timed out.
NotFound(String)
A requested resource (file, XORB, shard) does not exist.
DataIntegrity(String)
Data corruption: hash mismatches, invalid shard/xorb format, etc.
Configuration(String)
Invalid configuration or arguments supplied by the caller.
Io(String)
Local filesystem I/O failures.
Cancelled(String)
Generic cancellation from non-user sources (semaphore close, join cancellation).
Internal(String)
Catch-all for unexpected internal errors (panics, lock poison, bugs).
WrongRuntimeMode(String)
Caller invoked a method that is incompatible with the session’s runtime mode.
Implementations§
Trait Implementations§
Source§impl Error for XetError
impl Error for XetError
1.30.0 · 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<AcquireError> for XetError
impl From<AcquireError> for XetError
Source§fn from(e: AcquireError) -> Self
fn from(e: AcquireError) -> Self
Source§impl From<ClientError> for XetError
impl From<ClientError> for XetError
Source§fn from(e: ClientError) -> Self
fn from(e: ClientError) -> Self
Source§impl From<FileReconstructionError> for XetError
impl From<FileReconstructionError> for XetError
Source§fn from(e: FileReconstructionError) -> Self
fn from(e: FileReconstructionError) -> Self
Source§impl<T> From<PoisonError<MutexGuard<'_, T>>> for XetError
impl<T> From<PoisonError<MutexGuard<'_, T>>> for XetError
Source§fn from(e: PoisonError<MutexGuard<'_, T>>) -> Self
fn from(e: PoisonError<MutexGuard<'_, T>>) -> Self
Source§impl<T> From<PoisonError<RwLockReadGuard<'_, T>>> for XetError
impl<T> From<PoisonError<RwLockReadGuard<'_, T>>> for XetError
Source§fn from(e: PoisonError<RwLockReadGuard<'_, T>>) -> Self
fn from(e: PoisonError<RwLockReadGuard<'_, T>>) -> Self
Source§impl<T> From<PoisonError<RwLockWriteGuard<'_, T>>> for XetError
impl<T> From<PoisonError<RwLockWriteGuard<'_, T>>> for XetError
Source§fn from(e: PoisonError<RwLockWriteGuard<'_, T>>) -> Self
fn from(e: PoisonError<RwLockWriteGuard<'_, T>>) -> Self
Source§impl From<RuntimeError> for XetError
impl From<RuntimeError> for XetError
Source§fn from(e: RuntimeError) -> Self
fn from(e: RuntimeError) -> Self
Auto Trait Implementations§
impl Freeze for XetError
impl RefUnwindSafe for XetError
impl Send for XetError
impl Sync for XetError
impl Unpin for XetError
impl UnsafeUnpin for XetError
impl UnwindSafe for XetError
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
Source§impl<T> DropFlavorWrapper<T> for T
impl<T> DropFlavorWrapper<T> for T
Source§impl<T, W> HasTypeWitness<W> for Twhere
W: MakeTypeWitness<Arg = T>,
T: ?Sized,
impl<T, W> HasTypeWitness<W> for Twhere
W: MakeTypeWitness<Arg = T>,
T: ?Sized,
Source§impl<T> Identity for Twhere
T: ?Sized,
impl<T> Identity for Twhere
T: ?Sized,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> 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 moreSource§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.