Enum ethcore::error::BlockError
source · [−]pub enum BlockError {
Show 33 variants
TooManyUncles(OutOfBounds<usize>),
ExtraDataOutOfBounds(OutOfBounds<usize>),
InvalidSealArity(Mismatch<usize>),
TooMuchGasUsed(OutOfBounds<U256>),
GasTargetTooBig(OutOfBounds<U256>),
GasTargetTooSmall(OutOfBounds<U256>),
InvalidUnclesHash(Mismatch<H256>),
UncleTooOld(OutOfBounds<BlockNumber>),
UncleIsBrother(OutOfBounds<BlockNumber>),
UncleInChain(H256),
DuplicateUncle(H256),
UncleParentNotInChain(H256),
InvalidStateRoot(Mismatch<H256>),
InvalidGasUsed(Mismatch<U256>),
InvalidTransactionsRoot(Mismatch<H256>),
DifficultyOutOfBounds(OutOfBounds<U256>),
InvalidDifficulty(Mismatch<U256>),
MismatchedH256SealElement(Mismatch<H256>),
InvalidProofOfWork(OutOfBounds<U256>),
InvalidSeal,
InvalidGasLimit(OutOfBounds<U256>),
IncorrectBaseFee(Mismatch<U256>),
InvalidReceiptsRoot(Mismatch<H256>),
InvalidTimestamp(OutOfBounds<SystemTime>),
TemporarilyInvalid(OutOfBounds<SystemTime>),
InvalidLogBloom(Box<Mismatch<Bloom>>),
InvalidNumber(Mismatch<BlockNumber>),
RidiculousNumber(OutOfBounds<BlockNumber>),
TimestampOverflow,
TooManyTransactions(Address),
UnknownParent(H256),
UnknownUncleParent(H256),
UnknownEpochTransition(u64),
}
Expand description
Errors concerning block processing.
Variants
TooManyUncles(OutOfBounds<usize>)
Block has too many uncles.
ExtraDataOutOfBounds(OutOfBounds<usize>)
Extra data is of an invalid length.
InvalidSealArity(Mismatch<usize>)
Seal is incorrect format.
TooMuchGasUsed(OutOfBounds<U256>)
Block has too much gas used.
GasTargetTooBig(OutOfBounds<U256>)
Gas target increased too much from previous block
GasTargetTooSmall(OutOfBounds<U256>)
Gas target decreased too much from previous block
InvalidUnclesHash(Mismatch<H256>)
Uncles hash in header is invalid.
UncleTooOld(OutOfBounds<BlockNumber>)
An uncle is from a generation too old.
UncleIsBrother(OutOfBounds<BlockNumber>)
An uncle is from the same generation as the block.
UncleInChain(H256)
An uncle is already in the chain.
DuplicateUncle(H256)
An uncle is included twice.
UncleParentNotInChain(H256)
An uncle has a parent not in the chain.
InvalidStateRoot(Mismatch<H256>)
State root header field is invalid.
InvalidGasUsed(Mismatch<U256>)
Gas used header field is invalid.
InvalidTransactionsRoot(Mismatch<H256>)
Transactions root header field is invalid.
DifficultyOutOfBounds(OutOfBounds<U256>)
Difficulty is out of range; this can be used as an looser error prior to getting a definitive value for difficulty. This error needs only provide bounds of which it is out.
InvalidDifficulty(Mismatch<U256>)
Difficulty header field is invalid; this is a strong error used after getting a definitive value for difficulty (which is provided).
MismatchedH256SealElement(Mismatch<H256>)
Seal element of type H256 (max_hash for Ethash, but could be something else for other seal engines) is out of bounds.
InvalidProofOfWork(OutOfBounds<U256>)
Proof-of-work aspect of seal, which we assume is a 256-bit value, is invalid.
InvalidSeal
Some low-level aspect of the seal is incorrect.
InvalidGasLimit(OutOfBounds<U256>)
Gas limit header field is invalid.
IncorrectBaseFee(Mismatch<U256>)
Base fee is incorrect; base fee is different from the expected calculated value.
InvalidReceiptsRoot(Mismatch<H256>)
Receipts trie root header field is invalid.
InvalidTimestamp(OutOfBounds<SystemTime>)
Timestamp header field is invalid.
TemporarilyInvalid(OutOfBounds<SystemTime>)
Timestamp header field is too far in future.
InvalidLogBloom(Box<Mismatch<Bloom>>)
Log bloom header field is invalid.
InvalidNumber(Mismatch<BlockNumber>)
Number field of header is invalid.
RidiculousNumber(OutOfBounds<BlockNumber>)
Block number isn’t sensible.
TimestampOverflow
Timestamp header overflowed
TooManyTransactions(Address)
Too many transactions from a particular address.
UnknownParent(H256)
Parent given is unknown.
UnknownUncleParent(H256)
Uncle parent given is unknown.
UnknownEpochTransition(u64)
No transition to epoch number.
Trait Implementations
sourceimpl Clone for BlockError
impl Clone for BlockError
sourcefn clone(&self) -> BlockError
fn clone(&self) -> BlockError
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for BlockError
impl Debug for BlockError
sourceimpl Display for BlockError
impl Display for BlockError
sourceimpl Error for BlockError
impl Error for BlockError
sourcefn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
1.30.0 · sourcefn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
sourceimpl From<BlockError> for Error
impl From<BlockError> for Error
Error concerning block processing.
sourcefn from(e: BlockError) -> Self
fn from(e: BlockError) -> Self
Performs the conversion.
sourceimpl PartialEq<BlockError> for BlockError
impl PartialEq<BlockError> for BlockError
sourcefn eq(&self, other: &BlockError) -> bool
fn eq(&self, other: &BlockError) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &BlockError) -> bool
fn ne(&self, other: &BlockError) -> bool
This method tests for !=
.
impl Eq for BlockError
impl StructuralEq for BlockError
impl StructuralPartialEq for BlockError
Auto Trait Implementations
impl RefUnwindSafe for BlockError
impl Send for BlockError
impl Sync for BlockError
impl Unpin for BlockError
impl UnwindSafe for BlockError
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<Q, K> Equivalent<K> for Q where
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Q where
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
sourcepub fn equivalent(&self, key: &K) -> bool
pub fn equivalent(&self, key: &K) -> bool
Compare self to key
and return true
if they are equal.
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more