pub enum Error {
Show 40 variants ChainIdTooLong { chain_id: ChainId, len: usize, max_len: usize, }, InvalidHeader { reason: String, error: Error, }, InvalidTrustThreshold { reason: String, }, FailedTrustThresholdConversion { numerator: u64, denominator: u64, }, InvalidTendermintTrustThreshold(Error), InvalidMaxClockDrift { reason: String, }, InvalidLatestHeight { reason: String, }, MissingSignedHeader, Validation { reason: String, }, InvalidRawClientState { reason: String, }, MissingValidatorSet, MissingTrustedValidatorSet, MissingTrustedHeight, MissingTrustingPeriod, MissingUnbondingPeriod, NegativeMaxClockDrift, MissingLatestHeight, InvalidRawHeader(Error), InvalidRawMisbehaviour { reason: String, }, Decode(DecodeError), WrongTypeUrl { url: String, }, HeaderTimestampTooHigh { actual: String, max: String, }, HeaderTimestampTooLow { actual: String, min: String, }, TimestampOverflow(TimestampOverflowError), NotEnoughTimeElapsed { current_time: Timestamp, earliest_time: Timestamp, }, NotEnoughBlocksElapsed { current_height: Height, earliest_height: Height, }, InvalidHeaderHeight { height: u64, }, MismatchedRevisions { current_revision: u64, update_revision: u64, }, NotEnoughTrustedValsSigned { reason: VotingPowerTally, }, VerificationError { detail: VerificationErrorDetail, }, ProcessedTimeNotFound { client_id: ClientId, height: Height, }, ProcessedHeightNotFound { client_id: ClientId, height: Height, }, InsufficientHeight { latest_height: Height, target_height: Height, }, ClientFrozen { frozen_height: Height, target_height: Height, }, MisbehaviourTrustedValidatorHashMismatch { trusted_validator_set: Vec<Info>, next_validators_hash: Hash, trusted_val_hash: Hash, }, ConsensusStateTimestampGteTrustingPeriod { duration_since_consensus_state: Duration, trusting_period: Duration, }, MisbehaviourHeadersBlockHashesEqual, MisbehaviourHeadersNotAtSameHeight, MisbehaviourHeadersChainIdMismatch { header_chain_id: String, chain_id: String, }, InvalidRawClientId { client_id: String, },
}

Variants§

§

ChainIdTooLong

Fields

§chain_id: ChainId
§len: usize
§max_len: usize

chain-id is ({chain_id}) is too long, got: {len}, max allowed: {max_len}

§

InvalidHeader

Fields

§reason: String
§error: Error

invalid header, failed basic validation: {reason}, error: {error}

§

InvalidTrustThreshold

Fields

§reason: String

invalid client state trust threshold: {reason}

§

FailedTrustThresholdConversion

Fields

§numerator: u64
§denominator: u64

failed to build Tendermint domain type trust threshold from fraction: {numerator}/{denominator}

§

InvalidTendermintTrustThreshold(Error)

invalid tendermint client state trust threshold error: {0}

§

InvalidMaxClockDrift

Fields

§reason: String

invalid client state max clock drift: {reason}

§

InvalidLatestHeight

Fields

§reason: String

invalid client state latest height: {reason}

§

MissingSignedHeader

missing signed header

§

Validation

Fields

§reason: String

invalid header, failed basic validation: {reason}

§

InvalidRawClientState

Fields

§reason: String

invalid raw client state: {reason}

§

MissingValidatorSet

missing validator set

§

MissingTrustedValidatorSet

missing trusted validator set

§

MissingTrustedHeight

missing trusted height

§

MissingTrustingPeriod

missing trusting period

§

MissingUnbondingPeriod

missing unbonding period

§

NegativeMaxClockDrift

negative max clock drift

§

MissingLatestHeight

missing latest height

§

InvalidRawHeader(Error)

invalid raw header error: {0}

§

InvalidRawMisbehaviour

Fields

§reason: String

invalid raw misbehaviour: {reason}

§

Decode(DecodeError)

decode error: {0}

§

WrongTypeUrl

Fields

wrong type url for tendermint light client state: {url}

§

HeaderTimestampTooHigh

Fields

§actual: String

given other previous updates, header timestamp should be at most {max}, but was {actual}

§

HeaderTimestampTooLow

Fields

§actual: String

given other previous updates, header timestamp should be at least {min}, but was {actual}

§

TimestampOverflow(TimestampOverflowError)

timestamp overflowed error: {0}

§

NotEnoughTimeElapsed

Fields

§current_time: Timestamp
§earliest_time: Timestamp

not enough time elapsed, current timestamp {current_time} is still less than earliest acceptable timestamp {earliest_time}

§

NotEnoughBlocksElapsed

Fields

§current_height: Height
§earliest_height: Height

not enough blocks elapsed, current height {current_height} is still less than earliest acceptable height {earliest_height}

§

InvalidHeaderHeight

Fields

§height: u64

header revision height = {height} is invalid

§

MismatchedRevisions

Fields

§current_revision: u64
§update_revision: u64

the header’s current/trusted revision number ({current_revision}) and the update’s revision number ({update_revision}) should be the same

§

NotEnoughTrustedValsSigned

Fields

§reason: VotingPowerTally

not enough trust because insufficient validators overlap: {reason}

§

VerificationError

Fields

§detail: VerificationErrorDetail

verification failed: {detail}

§

ProcessedTimeNotFound

Fields

§client_id: ClientId
§height: Height

Processed time for the client {client_id} at height {height} not found

§

ProcessedHeightNotFound

Fields

§client_id: ClientId
§height: Height

Processed height for the client {client_id} at height {height} not found

§

InsufficientHeight

Fields

§latest_height: Height
§target_height: Height

the height is insufficient: latest_height={latest_height} target_height={target_height}

§

ClientFrozen

Fields

§frozen_height: Height
§target_height: Height

the client is frozen: frozen_height={frozen_height} target_height={target_height}

§

MisbehaviourTrustedValidatorHashMismatch

Fields

§trusted_validator_set: Vec<Info>
§next_validators_hash: Hash
§trusted_val_hash: Hash

trusted validators {trusted_validator_set:?}, does not hash to latest trusted validators. Expected: {next_validators_hash}, got: {trusted_val_hash}

§

ConsensusStateTimestampGteTrustingPeriod

Fields

§duration_since_consensus_state: Duration
§trusting_period: Duration

current timestamp minus the latest consensus state timestamp is greater than or equal to the trusting period ({duration_since_consensus_state:?} >= {trusting_period:?})

§

MisbehaviourHeadersBlockHashesEqual

headers block hashes are equal

§

MisbehaviourHeadersNotAtSameHeight

headers are not at same height and are monotonically increasing

§

MisbehaviourHeadersChainIdMismatch

Fields

§header_chain_id: String
§chain_id: String

header chain-id {header_chain_id} does not match the light client’s chain-id {chain_id})

§

InvalidRawClientId

Fields

§client_id: String

invalid raw client id: {client_id}

Trait Implementations§

source§

impl Debug for Error

source§

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

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

impl Display for Error

source§

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

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

impl Error for Error

source§

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

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

Auto Trait Implementations§

§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere 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 Twhere 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 Twhere 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 Twhere 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 Twhere 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.