Spec v1.7.0-alpha.6 and Gloas genesis (#9190)

Co-Authored-By: Josh King <josh@sigmaprime.io>

Co-Authored-By: Jimmy Chen <jchen.tc@gmail.com>

Co-Authored-By: Michael Sproul <michael@sigmaprime.io>
This commit is contained in:
jking-aus
2026-04-29 10:23:24 +02:00
committed by GitHub
parent e8c865dcc6
commit 16132a3694
35 changed files with 349 additions and 117 deletions

View File

@@ -9,8 +9,8 @@ use safe_arith::{SafeArith, SafeArithIter};
use tree_hash::TreeHash;
use types::{
AbstractExecPayload, BeaconState, BeaconStateError, ChainSpec, EthSpec, ExecPayload,
ExecutionBlockHash, ExpectedWithdrawals, ExpectedWithdrawalsCapella,
ExpectedWithdrawalsElectra, ExpectedWithdrawalsGloas, Validator, Withdrawal, Withdrawals,
ExpectedWithdrawals, ExpectedWithdrawalsCapella, ExpectedWithdrawalsElectra,
ExpectedWithdrawalsGloas, Validator, Withdrawal, Withdrawals,
};
/// Compute the next batch of withdrawals which should be included in a block.
@@ -495,10 +495,7 @@ pub mod gloas {
spec: &ChainSpec,
) -> Result<(), BlockProcessingError> {
// Return early if the parent block is empty.
let is_genesis_block = *state.latest_block_hash()? == ExecutionBlockHash::default();
let is_parent_block_empty =
*state.latest_block_hash()? != state.latest_execution_payload_bid()?.block_hash;
if is_genesis_block || is_parent_block_empty {
if *state.latest_block_hash()? != state.latest_execution_payload_bid()?.block_hash {
return Ok(());
}