pub enum BootstrapError {
Show 24 variants
CloudHome(CloudHomeError),
Encryption(EncryptionError),
Invite(Box<InviteError>),
Snapshot(SnapshotError),
Pull(PullError),
StorePull(StorePullError),
StoreRegistration(StoreRegistrationError),
DeviceJoin(DeviceJoinError),
Storage(StorageError),
Config(ConfigError),
Key(KeyError),
Io(Error),
InvalidCode(String),
StoreExists(String),
TornBootstrapCleanup {
store_id: String,
failures: String,
},
Provider(String),
Membership(String),
WritePolicyMismatch {
expected: WritePolicy,
actual: WritePolicy,
},
SerialCoordinationUnavailable {
provider: CloudProvider,
},
ExactSlotsUnavailable {
provider: CloudProvider,
},
Database(String),
InvalidSigningKey(String),
Cancelled,
Cleanup {
cleanup: String,
cause: Box<BootstrapError>,
},
}Expand description
Why joining or restoring a store failed. Both are the same operation — bootstrap a store from the cloud — differing only in their entry data (an invite that wraps the store key vs a restore code that carries the bucket credentials), so they share one error shape rather than two that duplicate most of their variants and then have to map between each other.
Variants§
CloudHome(CloudHomeError)
Encryption(EncryptionError)
Invite(Box<InviteError>)
Snapshot(SnapshotError)
Pull(PullError)
StorePull(StorePullError)
StoreRegistration(StoreRegistrationError)
DeviceJoin(DeviceJoinError)
Storage(StorageError)
Config(ConfigError)
Key(KeyError)
Io(Error)
InvalidCode(String)
StoreExists(String)
TornBootstrapCleanup
A hard crash left a store directory with no saved config, and clearing that torn-bootstrap residue before retrying failed — so the retry can’t proceed over the leftover directory or keyring entries.
Provider(String)
Membership(String)
WritePolicyMismatch
Database(String)
InvalidSigningKey(String)
Cancelled
The caller’s cancel signal fired at a phase boundary, so the join or restore stopped before saving the store. This returns through the same failure-cleanup path a real error takes — removing the partly-created store directory and any per-store keyring entries written so far — so a cancelled bootstrap leaves no residue in either place.
Cleanup
Bootstrap failed AND cleaning up what it had durably written also failed.
Both are carried: cause is the original bootstrap failure that
triggered the cleanup, cleanup is why the cleanup itself failed — the
cause is preserved as a value, not flattened into a string.
Trait Implementations§
Source§impl Debug for BootstrapError
impl Debug for BootstrapError
Source§impl Display for BootstrapError
impl Display for BootstrapError
Source§impl Error for BootstrapError
impl Error for BootstrapError
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<CloudHomeError> for BootstrapError
impl From<CloudHomeError> for BootstrapError
Source§fn from(source: CloudHomeError) -> Self
fn from(source: CloudHomeError) -> Self
Source§impl From<ConfigError> for BootstrapError
impl From<ConfigError> for BootstrapError
Source§fn from(source: ConfigError) -> Self
fn from(source: ConfigError) -> Self
Source§impl From<DeviceJoinError> for BootstrapError
impl From<DeviceJoinError> for BootstrapError
Source§fn from(source: DeviceJoinError) -> Self
fn from(source: DeviceJoinError) -> Self
Source§impl From<EncryptionError> for BootstrapError
impl From<EncryptionError> for BootstrapError
Source§fn from(source: EncryptionError) -> Self
fn from(source: EncryptionError) -> Self
Source§impl From<Error> for BootstrapError
impl From<Error> for BootstrapError
Source§impl From<InviteError> for BootstrapError
impl From<InviteError> for BootstrapError
Source§impl From<KeyError> for BootstrapError
impl From<KeyError> for BootstrapError
Source§impl From<PullError> for BootstrapError
impl From<PullError> for BootstrapError
Source§impl From<SnapshotError> for BootstrapError
impl From<SnapshotError> for BootstrapError
Source§impl From<StorageError> for BootstrapError
impl From<StorageError> for BootstrapError
Source§impl From<StorePullError> for BootstrapError
impl From<StorePullError> for BootstrapError
Auto Trait Implementations§
impl Freeze for BootstrapError
impl !RefUnwindSafe for BootstrapError
impl Send for BootstrapError
impl Sync for BootstrapError
impl Unpin for BootstrapError
impl UnsafeUnpin for BootstrapError
impl !UnwindSafe for BootstrapError
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<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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