diff --git a/specs/merge/fork-choice.md b/specs/merge/fork-choice.md index f62c8e014..342ef0f69 100644 --- a/specs/merge/fork-choice.md +++ b/specs/merge/fork-choice.md @@ -176,8 +176,8 @@ def on_block(store: Store, signed_block: SignedBeaconBlock) -> None: store.block_states[hash_tree_root(block)] = state # Add proposer score boost if the block is timely - if (get_current_slot(store) == block.slot and - store.time % SECONDS_PER_SLOT < SECONDS_PER_SLOT // ATTESTATION_OFFSET_QUOTIENT): + is_before_attestation_broadcast = store.time % SECONDS_PER_SLOT < SECONDS_PER_SLOT // ATTESTATION_OFFSET_QUOTIENT + if get_current_slot(store) == block.slot and is_before_attestation_broadcast: store.proposer_score_boost = LatestMessage( root=hash_tree_root(block), epoch=compute_epoch_at_slot(block.slot) diff --git a/specs/phase0/fork-choice.md b/specs/phase0/fork-choice.md index 5cb87a061..e3e18f9b1 100644 --- a/specs/phase0/fork-choice.md +++ b/specs/phase0/fork-choice.md @@ -114,7 +114,7 @@ def get_forkchoice_store(anchor_state: BeaconState, anchor_block: BeaconBlock) - anchor_epoch = get_current_epoch(anchor_state) justified_checkpoint = Checkpoint(epoch=anchor_epoch, root=anchor_root) finalized_checkpoint = Checkpoint(epoch=anchor_epoch, root=anchor_root) - proposer_score_boost = LatestMessage(root=Root(), epoch=Epoch(0)) + proposer_score_boost = LatestMessage(root=Root(), epoch=Epoch()) return Store( time=uint64(anchor_state.genesis_time + SECONDS_PER_SLOT * anchor_state.slot), genesis_time=anchor_state.genesis_time,