pub enum InternetArchiveError {
Show 15 variants
Http {
status: StatusCode,
code: Option<String>,
message: Option<String>,
raw_body: Option<String>,
},
MetadataWriteFailed {
message: String,
raw_body: Option<String>,
},
ItemNotFound {
identifier: String,
},
MissingAuth,
UploadConflict {
filename: String,
},
MissingFile {
filename: String,
},
InvalidState(String),
Timeout(&'static str),
Transport(Error),
Json(Error),
Xml(DeError),
Io(Error),
Url(ParseError),
EnvVar {
name: String,
source: VarError,
},
Identifier(IdentifierError),
}Expand description
Errors produced by the Internet Archive client.
Variants§
Http
The service returned a non-success HTTP response.
Fields
§
status: StatusCodeHTTP status code.
MetadataWriteFailed
Metadata write returned success: false.
Fields
ItemNotFound
A public item could not be found.
MissingAuth
The client was used for an authenticated operation without credentials.
UploadConflict
An upload policy rejected an existing file.
MissingFile
A requested file was not present on an item.
InvalidState(String)
A workflow invariant was violated.
Timeout(&'static str)
Polling timed out before the requested state was visible.
Transport(Error)
Request transport failed.
Json(Error)
JSON encoding or decoding failed.
Xml(DeError)
XML decoding failed.
Io(Error)
Local I/O failed.
Url(ParseError)
URL construction failed.
EnvVar
Environment lookup failed.
Identifier(IdentifierError)
Item identifier validation failed.
Trait Implementations§
Source§impl Debug for InternetArchiveError
impl Debug for InternetArchiveError
Source§impl Display for InternetArchiveError
impl Display for InternetArchiveError
Source§impl Error for InternetArchiveError
impl Error for InternetArchiveError
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()
Source§impl From<DeError> for InternetArchiveError
impl From<DeError> for InternetArchiveError
Source§impl From<Error> for InternetArchiveError
impl From<Error> for InternetArchiveError
Source§impl From<Error> for InternetArchiveError
impl From<Error> for InternetArchiveError
Source§impl From<Error> for InternetArchiveError
impl From<Error> for InternetArchiveError
Source§impl From<IdentifierError> for InternetArchiveError
impl From<IdentifierError> for InternetArchiveError
Source§fn from(source: IdentifierError) -> Self
fn from(source: IdentifierError) -> Self
Converts to this type from the input type.
Source§impl From<ParseError> for InternetArchiveError
impl From<ParseError> for InternetArchiveError
Source§fn from(source: ParseError) -> Self
fn from(source: ParseError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for InternetArchiveError
impl !RefUnwindSafe for InternetArchiveError
impl Send for InternetArchiveError
impl Sync for InternetArchiveError
impl Unpin for InternetArchiveError
impl UnsafeUnpin for InternetArchiveError
impl !UnwindSafe for InternetArchiveError
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