pub enum ErrorOrigin {
Endpoint,
Unattributed,
}Expand description
Where a DepsError was produced, which decides whether it counts as evidence about the
registry endpoint it was fetched from.
§Examples
use deps_core::DepsError;
use deps_core::error::ErrorOrigin;
let status = DepsError::HttpStatus { url: "https://registry.example/x".into(), status: 503 };
assert_eq!(status.origin(), ErrorOrigin::Endpoint);
assert_eq!(DepsError::RecentlyFailed.origin(), ErrorOrigin::Unattributed);Variants§
Endpoint
The endpoint produced or caused the error: a response was received, or the transport to it failed.
Unattributed
The error was raised locally (policy, parsing, cache, configuration) or cannot be tied to the endpoint. It neither vouches for the endpoint nor accuses it.
Trait Implementations§
Source§impl Clone for ErrorOrigin
impl Clone for ErrorOrigin
impl Copy for ErrorOrigin
Source§impl Debug for ErrorOrigin
impl Debug for ErrorOrigin
impl Eq for ErrorOrigin
Source§impl PartialEq for ErrorOrigin
impl PartialEq for ErrorOrigin
impl StructuralPartialEq for ErrorOrigin
Auto Trait Implementations§
impl Forget for ErrorOrigin
impl Freeze for ErrorOrigin
impl Move for ErrorOrigin
impl RefUnwindSafe for ErrorOrigin
impl Send for ErrorOrigin
impl Sync for ErrorOrigin
impl Unpin for ErrorOrigin
impl UnsafeUnpin for ErrorOrigin
impl UnwindSafe for ErrorOrigin
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.