pub enum BootstrapError {
Show 19 variants
Cancelled,
JoinRequestSent,
NoUnfinishedJoin(StoreId),
NoUnfinishedInstallation(StoreId),
RestoreRegistered,
NoUnfinishedRestore(StoreId),
NoUnfinishedReplacement(StoreId),
WrongAccount {
invited: String,
signed_in: String,
},
Code(CodeError),
Directory(BootstrapDirectoryError),
Store(CovenError),
DeviceLocked {
path: PathBuf,
},
Sync(SyncError),
OAuth(OAuthError),
SecureStorage(KeyError),
Cleanup {
operation: Box<BootstrapError>,
cleanup: Box<BootstrapError>,
},
Published {
handle: CovenHandle,
source: Box<BootstrapError>,
},
Shutdown(Shutdown),
Bug(Bug),
}Expand description
Opening a new installation failed. A join’s unpublished work, and a recorded restore’s, remain for an explicit retry unless the call was cancelled or the invite was settled; a restore before its record removes its own.
Variants§
Cancelled
Cancellation removes unpublished local data and leaves final custody alone.
JoinRequestSent
Cancelling a join after its request may have been sent. The join stays unfinished and resumable; it ends only by approval, decline or expiry (§13.2).
NoUnfinishedJoin(StoreId)
No join is under way for this store on this device: none was started here, or it has ended.
NoUnfinishedInstallation(StoreId)
No unfinished first installation of this store is on this device, or
a call holds it, so discard_unfinished_installation deleted nothing.
RestoreRegistered
Cancelling a restore once its device may be registered. The restore stays unfinished and listed, and only finishes (§13.1).
NoUnfinishedRestore(StoreId)
No restore is under way for this store on this device: none recorded itself here, or it has ended.
NoUnfinishedReplacement(StoreId)
No replacement of this device’s installation of the store is under way past its record: none recorded itself, or it has finished, or a connected reset’s kept record is gone.
WrongAccount
A join was signed in to another account than the one its invite shared the folder with. Nothing of that sign-in is kept and nothing is accepted or sent: the join stays listed, to resume with a sign-in to the invited account, or to cancel (§13.2).
Fields
Code(CodeError)
The code cannot be used for this operation.
Directory(BootstrapDirectoryError)
Preparing, publishing or removing the unpublished directory failed.
Store(CovenError)
Opening the database failed.
DeviceLocked
The device is locked, and the protection class the app chose keeps the installation’s files closed until it unlocks (api.md E1). A join’s unfinished installation stays for the retry, and a recorded restore’s; a restore before its record removes its own. The app waits for the unlock and calls again.
Sync(SyncError)
Provider admission, signed membership or snapshot loading failed.
OAuth(OAuthError)
Provider sign-in failed.
SecureStorage(KeyError)
Final custody could not be read or written.
Cleanup
Cleanup failed too; retry can inspect both failures.
Fields
operation: Box<BootstrapError>The initial failure.
cleanup: Box<BootstrapError>Its cleanup failure.
Published
The loaded store is published; confirming durability or final cleanup failed. Custody remains committed and the handle retains session-only keys.
Fields
handle: CovenHandleThe open store, including its session-only custody.
source: Box<BootstrapError>Failure after publication.
Shutdown(Shutdown)
The call’s runtime is shutting down and dropped its keychain work before it started, so nothing changed (E15).
Bug(Bug)
The call’s work panicked: a bug, which the caller reports (E15).
Trait Implementations§
Source§impl CarriesBug for BootstrapError
impl CarriesBug for BootstrapError
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
use the Display impl or to_string()
Source§impl From<BootstrapDirectoryError> for BootstrapError
impl From<BootstrapDirectoryError> for BootstrapError
Source§fn from(error: BootstrapDirectoryError) -> Self
fn from(error: BootstrapDirectoryError) -> Self
Source§impl From<Bug> for BootstrapError
impl From<Bug> for BootstrapError
Source§impl From<CodeError> for BootstrapError
impl From<CodeError> for BootstrapError
Source§impl From<CovenError> for BootstrapError
impl From<CovenError> for BootstrapError
Source§fn from(error: CovenError) -> Self
fn from(error: CovenError) -> Self
Source§impl From<DbError> for BootstrapError
A database call’s or opening’s failure is the store’s.
impl From<DbError> for BootstrapError
A database call’s or opening’s failure is the store’s.
Source§impl From<FileError> for BootstrapError
impl From<FileError> for BootstrapError
Source§impl From<KeyError> for BootstrapError
impl From<KeyError> for BootstrapError
Source§impl From<OAuthError> for BootstrapError
impl From<OAuthError> for BootstrapError
Source§fn from(error: OAuthError) -> Self
fn from(error: OAuthError) -> Self
Source§impl From<OpenError> for BootstrapError
impl From<OpenError> for BootstrapError
Source§impl From<Shutdown> for BootstrapError
impl From<Shutdown> for BootstrapError
Source§impl From<StoreLockError> for BootstrapError
impl From<StoreLockError> for BootstrapError
Source§fn from(error: StoreLockError) -> Self
fn from(error: StoreLockError) -> Self
Source§impl From<SyncError> for BootstrapError
A code sync refuses is refused as the call’s own code: a join’s, as a
restore’s.
impl From<SyncError> for BootstrapError
A code sync refuses is refused as the call’s own code: a join’s, as a restore’s.
Source§impl From<TaskFailed> for BootstrapError
impl From<TaskFailed> for BootstrapError
Source§fn from(failed: TaskFailed) -> Self
fn from(failed: TaskFailed) -> Self
Auto Trait Implementations§
impl !RefUnwindSafe for BootstrapError
impl !UnwindSafe for BootstrapError
impl Freeze for BootstrapError
impl Send for BootstrapError
impl Sync for BootstrapError
impl Unpin for BootstrapError
impl UnsafeUnpin 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<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<T> ErasedDestructor for Twhere
T: 'static,
impl<T> HostError for 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> ⓘ
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