mirror of
https://github.com/sigp/lighthouse.git
synced 2026-06-30 11:24:31 +00:00
Merge branch 'unstable' into eip4844
This commit is contained in:
@@ -45,8 +45,7 @@ use crate::{
|
||||
};
|
||||
use eth2::types::{EventKind, SseChainReorg, SseFinalizedCheckpoint, SseHead, SseLateHead};
|
||||
use fork_choice::{
|
||||
CountUnrealizedFull, ExecutionStatus, ForkChoiceView, ForkchoiceUpdateParameters, ProtoBlock,
|
||||
ResetPayloadStatuses,
|
||||
ExecutionStatus, ForkChoiceView, ForkchoiceUpdateParameters, ProtoBlock, ResetPayloadStatuses,
|
||||
};
|
||||
use itertools::process_results;
|
||||
use parking_lot::{Mutex, RwLock, RwLockReadGuard, RwLockWriteGuard};
|
||||
@@ -285,19 +284,13 @@ impl<T: BeaconChainTypes> CanonicalHead<T> {
|
||||
// defensive programming.
|
||||
mut fork_choice_write_lock: RwLockWriteGuard<BeaconForkChoice<T>>,
|
||||
reset_payload_statuses: ResetPayloadStatuses,
|
||||
count_unrealized_full: CountUnrealizedFull,
|
||||
store: &BeaconStore<T>,
|
||||
spec: &ChainSpec,
|
||||
log: &Logger,
|
||||
) -> Result<(), Error> {
|
||||
let fork_choice = <BeaconChain<T>>::load_fork_choice(
|
||||
store.clone(),
|
||||
reset_payload_statuses,
|
||||
count_unrealized_full,
|
||||
spec,
|
||||
log,
|
||||
)?
|
||||
.ok_or(Error::MissingPersistedForkChoice)?;
|
||||
let fork_choice =
|
||||
<BeaconChain<T>>::load_fork_choice(store.clone(), reset_payload_statuses, spec, log)?
|
||||
.ok_or(Error::MissingPersistedForkChoice)?;
|
||||
let fork_choice_view = fork_choice.cached_fork_choice_view();
|
||||
let beacon_block_root = fork_choice_view.head_block_root;
|
||||
let beacon_block = store
|
||||
|
||||
Reference in New Issue
Block a user