pub enum FetchError {
Request(RequestError),
Signing(String),
Redirect(String),
Status(u16),
NotActivityPub(String),
Invalid(String),
NoId,
CrossOrigin {
id: String,
url: Url,
},
ForeignAuthor {
id: String,
author: String,
},
Read(ReadError),
Portable(Vec<(String, String)>),
}Expand description
Why a fetch did not produce a document.
Variants§
Request(RequestError)
The request was not answered, or was refused before it was sent.
Signing(String)
The request could not be signed.
Redirect(String)
A redirect could not be followed: too many, no Location, or from
https to http.
Status(u16)
The server answered with a status other than success.
NotActivityPub(String)
The response is not ActivityPub; the content type it had.
Invalid(String)
The response is not a JSON object.
NoId
The document has no id.
CrossOrigin
The document’s id is not on the origin it was served from, and
nothing else vouches for it.
ForeignAuthor
The document names an author, in attributedTo or actor, on
another origin than its own id: its server cannot vouch that the
author wrote it.
Read(ReadError)
The document was established but is not a value of the type asked for.
Portable(Vec<(String, String)>)
No gateway served a portable object whose proof holds; why, for each gateway tried.
Implementations§
Trait Implementations§
Source§impl Debug for FetchError
impl Debug for FetchError
Source§impl Display for FetchError
impl Display for FetchError
Source§impl Error for FetchError
impl Error for FetchError
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<FetchError> for ResolveError
impl From<FetchError> for ResolveError
Source§fn from(error: FetchError) -> Self
fn from(error: FetchError) -> Self
Source§impl From<RequestError> for FetchError
impl From<RequestError> for FetchError
Source§fn from(error: RequestError) -> Self
fn from(error: RequestError) -> Self
Auto Trait Implementations§
impl !RefUnwindSafe for FetchError
impl !UnwindSafe for FetchError
impl Freeze for FetchError
impl Send for FetchError
impl Sync for FetchError
impl Unpin for FetchError
impl UnsafeUnpin for FetchError
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.