pub enum FlatChainstoreError {
Io(Error),
BlockNotFound,
IndexIsFull,
DbTooNew,
Poisoned,
InvalidMagic,
AccumulatorTooBig,
IndexTooBig,
InvalidMetadataPointer,
DbCorrupted,
InvalidValidationIndex,
}Available on crate feature
flat-chainstore only.Expand description
An error that can happen when we’re dealing with our flat chain store
Variants§
Io(Error)
An I/O error happened
Check the inner error for more information
BlockNotFound
We couldn’t find the block we were looking for
IndexIsFull
The index is full, we can’t add more blocks to it
DbTooNew
Tried to open a database that is too new for us
Poisoned
Our cache lock is poisoned
InvalidMagic
We encountered an invalid magic value. Possibly a database corruption
AccumulatorTooBig
The provided accumulator is too big
IndexTooBig
Tried to create an index more than 31 bits long
InvalidMetadataPointer
Something wrong happened with the metadata file mmap
DbCorrupted
The database is corrupted
InvalidValidationIndex
The validation index doesn’t have a height. This probably means it is in a fork or invalid chain
Trait Implementations§
Source§impl Debug for FlatChainstoreError
impl Debug for FlatChainstoreError
Source§impl From<Error> for FlatChainstoreError
impl From<Error> for FlatChainstoreError
Source§impl From<PoisonError<MutexGuard<'_, LruCache<BlockHash, DiskBlockHeader>>>> for FlatChainstoreError
impl From<PoisonError<MutexGuard<'_, LruCache<BlockHash, DiskBlockHeader>>>> for FlatChainstoreError
Source§fn from(
_: PoisonError<MutexGuard<'_, LruCache<BlockHash, DiskBlockHeader>>>,
) -> Self
fn from( _: PoisonError<MutexGuard<'_, LruCache<BlockHash, DiskBlockHeader>>>, ) -> Self
Converts to this type from the input type.
impl DatabaseError for FlatChainstoreError
Need this to use FlatChainstoreError as a DatabaseError in ChainStore
Auto Trait Implementations§
impl Freeze for FlatChainstoreError
impl !RefUnwindSafe for FlatChainstoreError
impl Send for FlatChainstoreError
impl Sync for FlatChainstoreError
impl Unpin for FlatChainstoreError
impl !UnwindSafe for FlatChainstoreError
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
§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>
Converts
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>
Converts
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