Enum celestia_types::Error

source ·
pub enum Error {
Show 40 variants UnsupportedNamespaceVersion(u8), InvalidNamespaceSize, Tendermint(Error), Protobuf(Error), Multihash(Error), CidError(CidError), LeopardCodec(LeopardError), MissingHeader, MissingCommit, MissingValidatorSet, MissingDataAvailabilityHeader, MissingProof, WrongProofType, UnsupportedShareVersion(u8), InvalidShareSize(usize), InvalidNmtLeafSize(usize), InvalidNmtNodeOrder, ShareSequenceLenExceeded(usize), InvalidNamespaceV0, InvalidNamespaceV255, InvalidNamespacedHash(InvalidNamespacedHash), InvalidSignatureIndex(usize, u64), InvalidAxis(i32), InvalidShwapProofType(i32), RangeProofError(RangeProofError), RootMismatch, UnexpectedAbsentSignature, Validation(ValidationError), Verification(VerificationError), MaxShareVersionExceeded(u8), Nmt(&'static str), InvalidAddressPrefix(String), InvalidAddressSize(usize), InvalidAddress(String), InvalidBalanceDenomination(String), InvalidBalanceAmount(String), UnsupportedFraudProofType(String), EdsIndexOutOfRange(u16, u16), EdsInvalidDimentions, ZeroBlockHeight,
}
Expand description

Representation of all the errors that can occur when interacting with celestia_types.

Variants§

§

UnsupportedNamespaceVersion(u8)

Unsupported namespace version.

§

InvalidNamespaceSize

Invalid namespace size.

§

Tendermint(Error)

Error propagated from the celestia_tendermint.

§

Protobuf(Error)

Error propagated from the celestia_tendermint_proto.

§

Multihash(Error)

Error propagated from the cid::multihash.

§

CidError(CidError)

Error returned when trying to compute new or parse existing CID. See blockstore::block

§

LeopardCodec(LeopardError)

Error propagated from the leopard_codec.

§

MissingHeader

Missing header.

§

MissingCommit

Missing commit.

§

MissingValidatorSet

Missing validator set.

§

MissingDataAvailabilityHeader

Missing data availability header.

§

MissingProof

Missing proof.

§

WrongProofType

Wrong proof type.

§

UnsupportedShareVersion(u8)

Unsupported share version.

§

InvalidShareSize(usize)

Invalid share size.

§

InvalidNmtLeafSize(usize)

Invalid nmt leaf size.

§

InvalidNmtNodeOrder

Invalid nmt node order.

§

ShareSequenceLenExceeded(usize)

Share sequence length exceeded.

§

InvalidNamespaceV0

Invalid namespace in version 0.

§

InvalidNamespaceV255

Invalid namespace in version 255.

§

InvalidNamespacedHash(InvalidNamespacedHash)

Invalid namespaced hash.

§

InvalidSignatureIndex(usize, u64)

Invalid index of signature in commit.

§

InvalidAxis(i32)

Invalid axis.

§

InvalidShwapProofType(i32)

Invalid Shwap proof type in Protobuf.

§

RangeProofError(RangeProofError)

Range proof verification error.

§

RootMismatch

Row root computed from shares doesn’t match one received in `DataAvailabilityHeaderz

§

UnexpectedAbsentSignature

Unexpected signature in absent commit.

§

Validation(ValidationError)

Error that happened during validation.

§

Verification(VerificationError)

Error that happened during verification.

§

MaxShareVersionExceeded(u8)

Max share version exceeded.

§

Nmt(&'static str)

An error related to the namespaced merkle tree.

§

InvalidAddressPrefix(String)

Invalid address bech32 prefix.

§

InvalidAddressSize(usize)

Invalid size of the address.

§

InvalidAddress(String)

Invalid address.

§

InvalidBalanceDenomination(String)

Invalid balance denomination.

§

InvalidBalanceAmount(String)

Invalid balance amount.

§

UnsupportedFraudProofType(String)

Unsupported fraud proof type.

§

EdsIndexOutOfRange(u16, u16)

Data square index out of range.

§

EdsInvalidDimentions

Could not create EDS, provided number of shares doesn’t form a pefect square

§

ZeroBlockHeight

Zero block height.

Trait Implementations§

source§

impl Debug for Error

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Display for Error

source§

fn fmt(&self, __formatter: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Error for Error

source§

fn source(&self) -> Option<&(dyn Error + 'static)>

Returns the lower-level source of this error, if any. Read more
1.0.0 · source§

fn description(&self) -> &str

👎Deprecated since 1.42.0: use the Display impl or to_string()
1.0.0 · source§

fn cause(&self) -> Option<&dyn Error>

👎Deprecated since 1.33.0: replaced by Error::source, which can support downcasting
source§

fn provide<'a>(&'a self, request: &mut Request<'a>)

🔬This is a nightly-only experimental API. (error_generic_member_access)
Provides type-based access to context intended for error reports. Read more
source§

impl From<CidError> for Error

source§

fn from(source: CidError) -> Self

Converts to this type from the input type.
source§

impl From<Error> for Error

source§

fn from(source: Error) -> Self

Converts to this type from the input type.
source§

impl From<Error> for Error

source§

fn from(source: Error) -> Self

Converts to this type from the input type.
source§

impl From<Error> for Error

source§

fn from(source: Error) -> Self

Converts to this type from the input type.
source§

impl From<InvalidNamespacedHash> for Error

source§

fn from(source: InvalidNamespacedHash) -> Self

Converts to this type from the input type.
source§

impl From<LeopardError> for Error

source§

fn from(source: LeopardError) -> Self

Converts to this type from the input type.
source§

impl From<ValidationError> for Error

source§

fn from(source: ValidationError) -> Self

Converts to this type from the input type.
source§

impl From<VerificationError> for Error

source§

fn from(source: VerificationError) -> Self

Converts to this type from the input type.

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> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> Same for T

§

type Output = T

Should always be Self
source§

impl<T> ToString for T
where T: Display + ?Sized,

source§

default fn to_string(&self) -> String

Converts the given value to a String. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

source§

fn vzip(self) -> V

source§

impl<S> CondSend for S
where S: Send,

source§

impl<S> CondSync for S
where S: Send + Sync,