mirror of
https://github.com/sigp/lighthouse.git
synced 2026-04-17 12:58:31 +00:00
Merge remote-tracking branch 'sigp/epoch-single-pass' into tree-states
This commit is contained in:
@@ -3,7 +3,6 @@ use eth2::lighthouse::{
|
||||
AttestationPerformance, AttestationPerformanceQuery, AttestationPerformanceStatistics,
|
||||
};
|
||||
use state_processing::{
|
||||
per_epoch_processing::altair::participation_cache::Error as ParticipationCacheError,
|
||||
per_epoch_processing::EpochProcessingSummary, BlockReplayError, BlockReplayer,
|
||||
};
|
||||
use std::sync::Arc;
|
||||
@@ -18,7 +17,6 @@ const BLOCK_ROOT_CHUNK_SIZE: usize = 100;
|
||||
enum AttestationPerformanceError {
|
||||
BlockReplay(#[allow(dead_code)] BlockReplayError),
|
||||
BeaconState(#[allow(dead_code)] BeaconStateError),
|
||||
ParticipationCache(#[allow(dead_code)] ParticipationCacheError),
|
||||
UnableToFindValidator(#[allow(dead_code)] usize),
|
||||
}
|
||||
|
||||
@@ -34,12 +32,6 @@ impl From<BeaconStateError> for AttestationPerformanceError {
|
||||
}
|
||||
}
|
||||
|
||||
impl From<ParticipationCacheError> for AttestationPerformanceError {
|
||||
fn from(e: ParticipationCacheError) -> Self {
|
||||
Self::ParticipationCache(e)
|
||||
}
|
||||
}
|
||||
|
||||
pub fn get_attestation_performance<T: BeaconChainTypes>(
|
||||
target: String,
|
||||
query: AttestationPerformanceQuery,
|
||||
|
||||
@@ -47,7 +47,6 @@ pub fn global_validator_inclusion_data<T: BeaconChainTypes>(
|
||||
|
||||
Ok(GlobalValidatorInclusionData {
|
||||
current_epoch_active_gwei: summary.current_epoch_total_active_balance(),
|
||||
previous_epoch_active_gwei: summary.previous_epoch_total_active_balance(),
|
||||
current_epoch_target_attesting_gwei: summary
|
||||
.current_epoch_target_attesting_balance()
|
||||
.map_err(convert_cache_error)?,
|
||||
|
||||
Reference in New Issue
Block a user