Merge branch 'remove-into-gossip-verified-block' of https://github.com/realbigsean/lighthouse into merge-unstable-deneb-june-6th

This commit is contained in:
realbigsean
2023-07-06 16:51:35 -04:00
78 changed files with 3075 additions and 407 deletions

View File

@@ -1,6 +1,8 @@
use super::signature_sets::Error as SignatureSetError;
use crate::per_epoch_processing::altair::participation_cache;
use crate::ContextError;
use merkle_proof::MerkleTreeError;
use participation_cache::Error as ParticipationCacheError;
use safe_arith::ArithError;
use ssz::DecodeError;
use types::*;
@@ -99,6 +101,7 @@ pub enum BlockProcessingError {
length: usize,
},
WithdrawalCredentialsInvalid,
ParticipationCacheError(ParticipationCacheError),
}
impl From<BeaconStateError> for BlockProcessingError {
@@ -156,6 +159,12 @@ impl From<BlockOperationError<HeaderInvalid>> for BlockProcessingError {
}
}
impl From<ParticipationCacheError> for BlockProcessingError {
fn from(e: ParticipationCacheError) -> Self {
BlockProcessingError::ParticipationCacheError(e)
}
}
/// A conversion that consumes `self` and adds an `index` variable to resulting struct.
///
/// Used here to allow converting an error into an upstream error that points to the object that