mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-21 22:04:44 +00:00
fix: set slot_number to latest_block_header.slot in Gloas fork upgrade (#8726)
During the Fulu→Gloas state upgrade, the latestExecutionPayloadHeader's slot_number was hardcoded to 0. This caused beacon state root divergence between Lighthouse and Lodestar at the Gloas fork boundary (slot 8). Set slot_number to pre.latest_block_header.slot to match Lodestar's behavior and correctly carry forward the slot of the last block. Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -64,7 +64,9 @@ pub fn upgrade_state_to_gloas<E: EthSpec>(
|
||||
current_sync_committee: pre.current_sync_committee.clone(),
|
||||
next_sync_committee: pre.next_sync_committee.clone(),
|
||||
// Execution - upgrade header from Fulu to Gloas
|
||||
latest_execution_payload_header: pre.latest_execution_payload_header.upgrade_to_gloas(),
|
||||
latest_execution_payload_header: pre
|
||||
.latest_execution_payload_header
|
||||
.upgrade_to_gloas(pre.latest_block_header.slot.into()),
|
||||
// Capella
|
||||
next_withdrawal_index: pre.next_withdrawal_index,
|
||||
next_withdrawal_validator_index: pre.next_withdrawal_validator_index,
|
||||
|
||||
Reference in New Issue
Block a user