#[non_exhaustive]pub enum Error {
Show 18 variants
UncleassifiedOperationError(Error),
OperationBuildFailed(Error),
ResultsProcessingFailed(Error),
AncillaryOperationFailed(Error),
ClientCreationFailed(Error),
KindMustBeSpecified,
KindDisabled(Kind),
Async(Error),
TokenAlwaysRequired(Kind),
TooManyResults,
UnsupportedOperation(Error),
UnsupportedState(RemoteObjectKind, String),
NameNotFound(RemoteObjectKind, String),
IdNotFound(RemoteObjectKind, String),
InvalidObjectSyntax(RemoteObjectKind, String, String),
InvalidIdSyntax(RemoteObjectKind, String, String),
UnsupportedRemoteUrlSyntax(String, String),
UrlHostMismatch {
url: String,
forge: String,
},
}
Expand description
Errors accessing forges
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
UncleassifiedOperationError(Error)
Forge operation error (unclassified)
Something went wrong accessing the forge. The error has not been more completely classified.
OperationBuildFailed(Error)
Forge operation build failed
The forge-specific client library rejected the attempted request or otherwise failed to construct an appropriate query to the forge.
This error occured before the actual forge was contacted.
ResultsProcessingFailed(Error)
Forge operation result processing failed
The principal forge operation completed successfully (at least as far as the forge-specific client library was concerned) but error occurred processing the results.
AncillaryOperationFailed(Error)
Forge ancillary operation failed
An error occurred while conducting operations ancillary to the principally-requested operation.
ClientCreationFailed(Error)
Forge client creation error
The operation to construct a forge client instance failed.
Perhaps the forge-kind-specific library did not like the
Config
.
KindMustBeSpecified
Forge kind must be specified
Config
contains Option<Kind>
so that it impl Default
and
for future compatibility. But the kind must, currently, always
be specified.
KindDisabled(Kind)
Forge kind disabled in this build
This build of the gitforge
library has been compiled without
support for the specified forge type.
Async(Error)
Async runtime failed
The asynchronous runtimee failed
TokenAlwaysRequired(Kind)
Token always required for this forge kind
Some forges (eg gitlab) always need a token and do not support anonymous API access.
TooManyResults
Search query had too many results.
See the discussion of Searching and limits by
ForgeMethods::request
. Narrow your search by providing more
parametsrs.
UnsupportedOperation(Error)
Unsupported operation
The operation is not supported on this kind of forge.
UnsupportedState(RemoteObjectKind, String)
Unsupported state in this context
A state or status field value in a request was not supported. Whether a particular state or status is supported might depend on the request.
NameNotFound(RemoteObjectKind, String)
Name refers to nonexistent remote object
IdNotFound(RemoteObjectKind, String)
Id or number refers to nonexistent remote object
InvalidObjectSyntax(RemoteObjectKind, String, String)
Invalid object syntax
InvalidIdSyntax(RemoteObjectKind, String, String)
Invalid id or number syntax
UnsupportedRemoteUrlSyntax(String, String)
Unsupported remote URL format
UrlHostMismatch
Remote URL does not match the forge hsotname
Trait Implementations§
Source§impl Error for Error
impl Error for Error
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
Auto Trait Implementations§
impl Freeze for Error
impl RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnwindSafe for Error
Blanket Implementations§
Source§impl<T> AsErrorSource for Twhere
T: Error + 'static,
impl<T> AsErrorSource for Twhere
T: Error + 'static,
Source§fn as_error_source(&self) -> &(dyn Error + 'static)
fn as_error_source(&self) -> &(dyn Error + 'static)
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> 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 more