pub enum ClientError {
Show 29 variants
NoHomeRegistryUrl,
ResettingRegistryLocalStateFailed,
ClearContentCacheFailed,
Unauthorized(String),
InvalidCheckpointSignature,
InvalidCheckpointKeyId {
key_id: KeyID,
},
NoOperatorRecords,
OperatorValidationFailed {
inner: ValidationError,
},
CannotInitializePackage {
name: PackageName,
init_record_id: Option<RecordId>,
},
MustInitializePackage {
name: PackageName,
has_auth_token: bool,
},
NotPublishing,
NothingToPublish {
name: PackageName,
},
PackageDoesNotExist {
name: PackageName,
has_auth_token: bool,
},
PackageDoesNotExistWithHintHeader {
name: PackageName,
has_auth_token: bool,
hint_namespace: String,
hint_registry: String,
},
PackageVersionDoesNotExist {
version: Version,
name: PackageName,
},
PackageVersionRequirementDoesNotExist {
version: VersionReq,
name: PackageName,
},
PackageValidationFailed {
name: PackageName,
inner: ValidationError,
},
ContentNotFound {
digest: AnyHash,
},
IncorrectContent {
digest: AnyHash,
expected: AnyHash,
},
PackageLogEmpty {
name: PackageName,
},
PublishRejected {
name: PackageName,
record_id: RecordId,
reason: String,
},
ConflictPendingPublish {
name: PackageName,
record_id: RecordId,
pending_record_id: RecordId,
},
PackageMissingContent,
CheckpointLogLengthRewind {
from: RegistryLen,
to: RegistryLen,
},
CheckpointChangedLogRootOrMapRoot {
log_length: RegistryLen,
},
Keyring(KeyringError),
Api(ClientError),
Other(Error),
IoError(Error),
}
Expand description
Represents an error returned by Warg registry clients.
Variants§
NoHomeRegistryUrl
No home registry registry server URL is configured.
ResettingRegistryLocalStateFailed
Reset registry local state.
ClearContentCacheFailed
Clearing content local cache.
Unauthorized rejection
InvalidCheckpointSignature
Checkpoint signature failed verification
InvalidCheckpointKeyId
Checkpoint signature failed verification
NoOperatorRecords
The server did not provide operator records.
OperatorValidationFailed
The operator failed validation.
Fields
inner: ValidationError
The validation error.
CannotInitializePackage
The package already exists and cannot be initialized.
Fields
name: PackageName
The package name that already exists.
MustInitializePackage
The package must be initialized before publishing.
Fields
name: PackageName
The name of the package that must be initialized.
NotPublishing
There is no publish operation in progress.
NothingToPublish
The package has no records to publish.
Fields
name: PackageName
The package that has no publish operations.
PackageDoesNotExist
The package does not exist.
Fields
name: PackageName
The missing package.
PackageDoesNotExistWithHintHeader
The package does not exist with hint header.
Fields
name: PackageName
The missing package.
PackageVersionDoesNotExist
The package version does not exist.
Fields
name: PackageName
The package with the missing version.
PackageVersionRequirementDoesNotExist
The package version requirement does not exist.
Fields
version: VersionReq
The missing version requirement of the package.
name: PackageName
The package with the missing version.
PackageValidationFailed
The package failed validation.
Fields
name: PackageName
The package that failed validation.
inner: ValidationError
The validation error.
ContentNotFound
Content was not found during a publish operation.
IncorrectContent
Content digest was different than expected.
PackageLogEmpty
The package log is empty and cannot be validated.
Fields
name: PackageName
The package with an empty package log.
PublishRejected
A publish operation was rejected.
Fields
name: PackageName
The package that was rejected.
ConflictPendingPublish
A publish operation was rejected due to conflicting pending publish.
Fields
name: PackageName
The package that was rejected.
PackageMissingContent
The package is still missing content.
CheckpointLogLengthRewind
The registry provided a latest checkpoint with a log length less than a previously provided checkpoint log length.
Fields
from: RegistryLen
The previously received checkpoint log length.
to: RegistryLen
The latest checkpoint log length.
CheckpointChangedLogRootOrMapRoot
The registry provided a checkpoint with a different log_root
and
map_root
than a previously provided checkpoint.
Fields
log_length: RegistryLen
The checkpoint log length.
Keyring(KeyringError)
An error occurred while accessing the keyring.
Api(ClientError)
An error occurred during an API operation.
Other(Error)
An error occurred while performing a client operation.
IoError(Error)
An error occurred while performing a IO.
Trait Implementations§
Source§impl Debug for ClientError
impl Debug for ClientError
Source§impl Display for ClientError
impl Display for ClientError
Source§impl Error for ClientError
impl Error for ClientError
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
Source§impl From<ClientError> for ClientError
impl From<ClientError> for ClientError
Source§fn from(source: ClientError) -> Self
fn from(source: ClientError) -> Self
Source§impl From<Error> for ClientError
impl From<Error> for ClientError
Source§impl From<Error> for ClientError
impl From<Error> for ClientError
Source§impl From<KeyringError> for ClientError
impl From<KeyringError> for ClientError
Source§fn from(source: KeyringError) -> Self
fn from(source: KeyringError) -> Self
Auto Trait Implementations§
impl !Freeze for ClientError
impl !RefUnwindSafe for ClientError
impl Send for ClientError
impl Sync for ClientError
impl Unpin for ClientError
impl !UnwindSafe for ClientError
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> 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.