[][src]Enum state_processing::per_block_processing::errors::AttestationInvalid

pub enum AttestationInvalid {
    BadShard,
    IncludedTooEarly {
        state: Slot,
        delay: u64,
        attestation: Slot,
    },
    IncludedTooLate {
        state: Slot,
        attestation: Slot,
    },
    BadTargetEpoch,
    WrongJustifiedCheckpoint {
        state: Checkpoint,
        attestation: Checkpoint,
        is_current: bool,
    },
    BadParentCrosslinkHash,
    BadParentCrosslinkStartEpoch,
    BadParentCrosslinkEndEpoch,
    CustodyBitfieldHasSetBits,
    AggregationBitfieldIsEmpty,
    BadCustodyBitfieldLength {
        committee_len: usize,
        bitfield_len: usize,
    },
    BadAggregationBitfieldLength {
        committee_len: usize,
        bitfield_len: usize,
    },
    CustodyBitfieldNotSubset,
    NoCommitteeForShard {
        shard: u64,
        slot: Slot,
    },
    BadSignature,
    ShardBlockRootNotZero,
    BadIndexedAttestation(IndexedAttestationInvalid),
}

Describes why an object is invalid.

Variants

BadShard

Shard exceeds SHARD_COUNT.

IncludedTooEarly

Attestation included before the inclusion delay.

Fields of IncludedTooEarly

state: Slotdelay: u64attestation: Slot
IncludedTooLate

Attestation slot is too far in the past to be included in a block.

Fields of IncludedTooLate

state: Slotattestation: Slot
BadTargetEpoch

Attestation target epoch does not match the current or previous epoch.

WrongJustifiedCheckpoint

Attestation justified checkpoint doesn't match the state's current or previous justified checkpoint.

is_current is true if the attestation was compared to the state.current_justified_checkpoint, false if compared to state.previous_justified_checkpoint.

Fields of WrongJustifiedCheckpoint

state: Checkpointattestation: Checkpointis_current: bool
BadParentCrosslinkHash

Attestation crosslink root does not match the state crosslink root for the attestations slot.

BadParentCrosslinkStartEpoch

Attestation crosslink start epoch does not match the end epoch of the state crosslink.

BadParentCrosslinkEndEpoch

Attestation crosslink end epoch does not match the expected value.

CustodyBitfieldHasSetBits

The custody bitfield has some bits set true. This is not allowed in phase 0.

AggregationBitfieldIsEmpty

There are no set bits on the attestation -- an attestation must be signed by at least one validator.

BadCustodyBitfieldLength

The custody bitfield length is not the smallest possible size to represent the committee.

Fields of BadCustodyBitfieldLength

committee_len: usizebitfield_len: usize
BadAggregationBitfieldLength

The aggregation bitfield length is not the smallest possible size to represent the committee.

Fields of BadAggregationBitfieldLength

committee_len: usizebitfield_len: usize
CustodyBitfieldNotSubset

The bits set in the custody bitfield are not a subset of those set in the aggregation bits.

NoCommitteeForShard

There was no known committee in this epoch for the given shard and slot.

Fields of NoCommitteeForShard

shard: u64slot: Slot
BadSignature

The attestation signature verification failed.

ShardBlockRootNotZero

The shard block root was not set to zero. This is a phase 0 requirement.

BadIndexedAttestation(IndexedAttestationInvalid)

The indexed attestation created from this attestation was found to be invalid.

Trait Implementations

impl PartialEq<AttestationInvalid> for AttestationInvalid[src]

impl Debug for AttestationInvalid[src]

Auto Trait Implementations

impl Send for AttestationInvalid

impl Unpin for AttestationInvalid

impl Sync for AttestationInvalid

impl UnwindSafe for AttestationInvalid

impl RefUnwindSafe for AttestationInvalid

Blanket Implementations

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> SendSyncUnwindSafe for T where
    T: Send + Sync + UnwindSafe + ?Sized

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