Merge branch 'unstable' into dev/etan/lc-electra

This commit is contained in:
Etan Kissling 2024-06-23 15:54:46 +02:00
commit 4e8e316012
No known key found for this signature in database
GPG Key ID: B21DA824C5A3D03D

View File

@ -611,11 +611,17 @@ iterator makeTestBlocks*(
let
parent_root = withState(state[]): forkyState.latest_block_root
attestations =
if attested:
if attested and state.kind < ConsensusFork.Electra:
makeFullAttestations(
state[], parent_root, getStateField(state[], slot), cache)
else:
@[]
electraAttestations =
if attested and state.kind >= ConsensusFork.Electra:
makeFullElectraAttestations(
state[], parent_root, getStateField(state[], slot), cache)
else:
@[]
stateEth1 = getStateField(state[], eth1_data)
stateDepositIndex = getStateField(state[], eth1_deposit_index)
deposits =
@ -633,7 +639,8 @@ iterator makeTestBlocks*(
state[], cache,
eth1_data = eth1_data,
attestations = attestations,
electraAttestations = electraAttestations,
deposits = deposits,
sync_aggregate = sync_aggregate,
graffiti = graffiti,
cfg = cfg)
cfg = cfg)