spectest alpha 12 compliance (spec pin bump and assorted fix commits) - #17310
Open
kasey wants to merge 14 commits into
Open
spectest alpha 12 compliance (spec pin bump and assorted fix commits)#17310kasey wants to merge 14 commits into
kasey wants to merge 14 commits into
Conversation
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
from
August 5, 2026 20:57
65b033a to
c753de8
Compare
kasey
force-pushed
the
local-spectest-refactors
branch
from
August 5, 2026 20:57
e6f59b0 to
0bb7aa1
Compare
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
from
August 5, 2026 21:08
c753de8 to
a719bf5
Compare
kasey
force-pushed
the
local-spectest-refactors
branch
from
August 5, 2026 21:08
0bb7aa1 to
7c3e3c2
Compare
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
from
August 5, 2026 21:13
a719bf5 to
d38b15f
Compare
kasey
force-pushed
the
local-spectest-refactors
branch
2 times, most recently
from
August 5, 2026 21:16
68dcf4b to
9de1e3f
Compare
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
2 times, most recently
from
August 5, 2026 21:18
50ebff4 to
6309ceb
Compare
kasey
force-pushed
the
local-spectest-refactors
branch
from
August 5, 2026 21:18
9de1e3f to
5ef6291
Compare
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
from
August 5, 2026 22:00
6309ceb to
5fb8e30
Compare
kasey
force-pushed
the
local-spectest-refactors
branch
from
August 5, 2026 22:00
5ef6291 to
bc34380
Compare
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
from
August 6, 2026 01:12
5fb8e30 to
0bcbabb
Compare
kasey
force-pushed
the
local-spectest-refactors
branch
2 times, most recently
from
August 6, 2026 01:31
66c0cfa to
e77427a
Compare
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
from
August 6, 2026 01:31
0bcbabb to
f389084
Compare
kasey
force-pushed
the
local-spectest-refactors
branch
from
August 6, 2026 05:25
e77427a to
159e1ac
Compare
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
2 times, most recently
from
August 6, 2026 05:41
d4f6ac6 to
81641a7
Compare
kasey
force-pushed
the
local-spectest-refactors
branch
from
August 6, 2026 05:41
159e1ac to
1b96281
Compare
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
from
August 6, 2026 05:49
81641a7 to
7bdbab9
Compare
kasey
force-pushed
the
local-spectest-refactors
branch
from
August 6, 2026 05:49
1b96281 to
33833a1
Compare
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
3 times, most recently
from
August 6, 2026 08:32
821840a to
fbb1b4c
Compare
kasey
force-pushed
the
local-spectest-refactors
branch
from
August 6, 2026 13:27
4a6e4ef to
c592869
Compare
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
from
August 6, 2026 13:27
fbb1b4c to
34579ea
Compare
kasey
force-pushed
the
local-spectest-refactors
branch
from
August 6, 2026 17:25
c592869 to
49ac6e9
Compare
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
from
August 6, 2026 17:26
34579ea to
d8319b2
Compare
terencechain
reviewed
Aug 6, 2026
| set.Bool(DisableProgressiveSSZ.Name, false, "test") | ||
| require.NoError(t, set.Set(DisableProgressiveSSZ.Name, "true")) | ||
| require.NoError(t, ConfigureBeaconChain(ctx)) | ||
| assert.Equal(t, true, Get().DisableProgressiveSSZ) |
Collaborator
There was a problem hiding this comment.
the old test had defer Init(&Flags{}) w/o it this leaves DisableProgressiveSSZ=true in the package global config for whatever test runs after this one
Comment on lines
+31
to
+37
| // # [New in Gloas:EIP7688] | ||
| // assert len(body.proposer_slashings) <= MAX_PROPOSER_SLASHINGS | ||
| // assert len(body.attester_slashings) <= MAX_ATTESTER_SLASHINGS_ELECTRA | ||
| // assert len(body.attestations) <= MAX_ATTESTATIONS_ELECTRA | ||
| // assert len(body.voluntary_exits) <= MAX_VOLUNTARY_EXITS | ||
| // assert len(body.bls_to_execution_changes) <= MAX_BLS_TO_EXECUTION_CHANGES | ||
| // assert len(body.payload_attestations) <= MAX_PAYLOAD_ATTESTATIONS |
Collaborator
There was a problem hiding this comment.
we dont need these assertions because ssz unmarshal would have failed earlier right?
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
from
August 7, 2026 20:00
d8319b2 to
1e7be40
Compare
kasey
force-pushed
the
local-spectest-refactors
branch
from
August 7, 2026 20:00
49ac6e9 to
0d8a5ee
Compare
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
from
August 11, 2026 14:29
1e7be40 to
8ca31d6
Compare
kasey
force-pushed
the
local-spectest-refactors
branch
from
August 11, 2026 14:29
0d8a5ee to
a10e16d
Compare
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
from
August 11, 2026 19:34
8ca31d6 to
730446a
Compare
kasey
force-pushed
the
local-spectest-refactors
branch
from
August 11, 2026 19:34
a10e16d to
71436f8
Compare
Marks the Gloas containers and collections that EIP-7688 makes progressive: the beacon state, block body, attestation and its aggregate wrappers, the payload bid and envelope, the Gloas execution payload and execution requests, and the data column sidecar. Generation stays gated off by default, so this commit changes no generated code: the emitted hash tree roots still match the pinned spectest fixtures. Building with --//tools:disable_progressive_merkleization=false, or regenerating with SSZ_PROGRESSIVE=1, switches the annotated types over to ProgressiveHashTreeRoot and the progressive collection validators.
…ault Note: the generated code is modified in the following commit, so at this commit the generated code does not match the output of the build toolchain.
…ped to default-on
Ignore builder deposit requests whose withdrawal credentials do not carry BUILDER_WITHDRAWAL_PREFIX, both when batching new registrations and when processing an individual request. Such deposits are dropped and the funds are lost, matching the spec. Register new builders with PAYLOAD_BUILDER_VERSION rather than echoing the first credential byte, so the stored version cannot be influenced by the depositor.
An exited builder's withdrawable epoch was pushed out on every top-up, which let a builder with a pending balance defer its own withdrawal indefinitely. Only reset when the builder has actually been swept, and evaluate that before crediting the top-up so the new deposit does not mask a zero balance. Also guard against a nil builder at a known index rather than dereferencing it.
Gloas drops MAX_DEPOSIT_REQUESTS_PER_PAYLOAD; the execution layer bounds deposit requests through the block gas limit instead. Lift the cap in the Gloas request list decoder. The remaining per-payload maxima (withdrawals, consolidations, builder deposits and builder exits) are still consensus checks, so assert them explicitly in ApplyParentExecutionPayload rather than relying on the SSZ list limits, which no longer bound the progressive types.
Align the builder withdrawal credential prefix with the Gloas spec value of 0xB0 in both the mainnet and minimal configs. It was previously 0x03, which collided with the range reserved for future credential types.
Lower MIN_BUILDER_WITHDRAWABILITY_DELAY from 8192 to 64 epochs so an exiting builder's funds are not locked for an impractically long window, and lower MAX_BUILDER_DEPOSIT_REQUESTS_PER_PAYLOAD from 2**8 to 2**6 to match the current Gloas spec.
Move the payload deadline to the midpoint of the slot so builders have to reveal earlier, giving the PTC more time to attest to timeliness. Note: config/params TestLoadConfigFile now diverges from the pinned consensus-spec fixture, which still carries PAYLOAD_DUE_BPS 7500. This needs the spec test pin to advance before it can merge to develop.
kasey
force-pushed
the
local-spectest-refactors
branch
from
August 12, 2026 20:32
71436f8 to
a676232
Compare
kasey
force-pushed
the
spectest-alpha-12-compliance
branch
from
August 12, 2026 20:32
730446a to
9a4debc
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Gloas devnet-7 spec update: progressive merkleization on by default, builder config alignment, attestation parent-slot fixes
This PR moves the consensus spec test pin from
v1.7.0-alpha.11tov1.7.0-alpha.12and lands everything needed to pass against those fixtures. Two spec changes drive the bulk of the diff. First, the alpha.13 fixtures merkleize Gloas containers per EIP-7688, so progressive merkleization can no longer be an off-by-default experiment: the annotations are added to the Gloas types and the codegen/runtime defaults are inverted so that progressive is what you get unless you explicitly opt out. The rest is Gloas builder work: three config/preset values move to their current spec values, the builder withdrawal credential prefix is corrected and then actually enforced on deposit requests, and a builder could previously defer its own withdrawal indefinitely by topping itself up.Spec test pin
WORKSPACE:consensus_spec_versionv1.7.0-alpha.11→v1.7.0-alpha.12, with new fixture hashes for the general/minimal/mainnet flavors and a new integrity hash for theconsensus-specssource tarball.Progressive merkleization (EIP-7688) becomes the default
Type annotations
proto/prysm/v1alpha1/gloas.yamlandproto/engine/v1/engine.yamlmark the containers and collections that EIP-7688 makes progressive:BeaconStateGloas(validators, balances, both participation lists, inactivity scores, pending deposits/partial withdrawals/consolidations, builders, builder pending withdrawals, payload expected withdrawals),BeaconBlockBodyGloas(all operation lists plus payload attestations),AttestationGloas(AggregationBitsasProgressiveBitlist),IndexedAttestationGloas(AttestingIndices),ExecutionPayloadBid(BlobKzgCommitments),ExecutionPayloadGloas(transactions as a progressive list of progressive byte lists, withdrawals, block access list), andExecutionRequestsGloas(all five request lists).ExecutionPayloadEnvelope,PayloadAttestation.DataColumnSidecarGloasgets progressiveColumnandKzgProofslists but stays a standard container.ExecutionRequestsmessage is deliberately left alone, with a comment explaining why: it is the electra/fulu type, and annotating it would leak progressive merkleization into pre-Gloas forks. Gloas uses the separateExecutionRequestsGloasmessage.Default flip: codegen, Bazel, feature flag
build/gen/ssz.go: progressive generation now defaults to on.SSZ_PROGRESSIVE=0generates the bounded form (previously the default was off andSSZ_PROGRESSIVE=1opted in)..bazelrc: comment documenting that progressive is the build default and that--//tools:disable_progressive_merkleizationswitches to the bounded form. Thebool_flagdefault in//toolsalready had progressive enabled; no rule change was needed.--enable-progressive-sszflag becomes--disable-progressive-ssz, andfeatures.Flags.EnableProgressiveSSZbecomesDisableProgressiveSSZ.features.ProgressiveSSZEnabled(version)is nowversion >= Gloas && !DisableProgressiveSSZ. The flag usage string calls it an escape hatch for debugging, since Gloas mandates progressive merkleization.features.ProgressiveSSZEnabledso the version gate is applied consistently:beacon-chain/light-client/lightclient.go(progressiveExecutionPayloadSSZEnabled) andconsensus-types/blocks/proofs.go(blockBodyListRoot).Regenerated SSZ
proto/prysm/v1alpha1/gloas{,.minimal}.ssz.goandproto/engine/v1/engine{,.minimal}.ssz.goare regenerated: annotated types now exposeProgressiveHashTreeRoot/ProgressiveHashTreeRootWith(withHashTreeRootdelegating to them), merkleize viaMerkleizeProgressiveWithActiveFields/MerkleizeProgressiveWithMixin, and usePutProgressiveBitlist/ValidateProgressiveBitlist. The boundedErrListTooBigandValidateBitlistchecks are dropped from marshal, unmarshal, and hashing.Note the commit split:
deb157079cinverts the config and tests, and8cf24656adcommits the regenerated output, so the generated code does not match the toolchain at the intermediate commit.Length checks SSZ no longer provides
Because the progressive types no longer carry list limits,
ApplyParentExecutionPayloadnow asserts the per-payload maxima explicitly via a newvalidateExecutionRequestLengths(withdrawal requests, consolidations, builder deposits, builder exits), matchingapply_parent_execution_payloadin the spec.Config and preset changes
Applied to both
config/params/mainnet_config.goand, where relevant,config/params/minimal_config.go:BUILDER_WITHDRAWAL_PREFIX0x030xB0(mainnet and minimal)MIN_BUILDER_WITHDRAWABILITY_DELAYMAX_BUILDER_DEPOSIT_REQUESTS_PER_PAYLOAD2**8)2**6)PAYLOAD_DUE_BPS0x03collided with the range reserved for future credential types. The withdrawability delay change keeps an exiting builder's funds from being locked for an impractically long window.PAYLOAD_DUE_BPSat 5000 moves the payload deadline to the slot midpoint so builders reveal earlier and the PTC has more time to attest to timeliness; that commit notesconfig/paramsTestLoadConfigFiledepends on the pinned consensus-spec config fixture, which is why it needs the spec test pin bump that is included in this same PR.Builder deposit and withdrawal handling
beacon-chain/core/gloas/builder_deposit_request.go): builder deposit requests whose withdrawal credentials lackBUILDER_WITHDRAWAL_PREFIXare now ignored, both when batching new registrations inProcessBuilderDepositRequestsand inprocessBuilderDepositRequest. Such deposits are dropped and the funds are lost, per spec.beacon-chain/state/state-native/setters_gloas.go):AddBuilderFromDepositregisters new builders withPAYLOAD_BUILDER_VERSIONinstead of echoingwithdrawalCredentials[0], so a depositor can no longer influence the stored version.WithdrawableEpochwas pushed out on every top-up, letting a builder with a pending balance defer its own withdrawal indefinitely. The reset now requiresBalance == 0(actually swept) in addition to being exited, and is evaluated before the top-up is credited so the new deposit cannot mask a zero balance. A nil builder at a known index now returns an error rather than being dereferenced.proto/engine/v1/electra.go): Gloas dropsMAX_DEPOSIT_REQUESTS_PER_PAYLOAD— the execution layer bounds deposit requests through the block gas limit — sodecodeExecutionRequestListGloasraiseslimits.Depositsto the size-derived maximum. Covered by the newTestGetDecodedExecutionRequestsGloas_NoDepositLimit;TestEmptyExecutionRequestsGloasHashTreeRootis also added.Spec test runner changes
testing/spectest/shared/gloas/ssz_static/ssz_static.go: thePROGRESSIVE_SSZenv override now clearsDisableProgressiveSSZrather than setting the old enable flag; the comment is updated for the inverted default.execution_payload_bid.goadapts to the newProcessExecutionPayloadBidsignature.TestForkChoice_InsertNode_LateBlockNotRecordedcovers the new gate, andTestForkChoice_InsertNode_RecordsFirstSeennow sets a genesis time so the inserted block lands in the current slot.Behavior notes
process_operationspseudocode adds EIP-7688 length asserts on the block body's operation lists (proposer slashings, attester slashings, attestations, voluntary exits, BLS-to-execution changes, payload attestations). Those asserts are recorded in the spec comment but not yet mirrored ingloasOperations; the analogous checks for the execution request lists are implemented here inApplyParentExecutionPayload. Worth a follow-up now that the progressive SSZ types no longer bound those lists.ssz_staticagainst progressive fixtures still needsPROGRESSIVE_SSZ=1to align the native-state root with the generated one; the runtime feature gate and the codegen flag remain independent.Commits
37b4e29a5dMove spectests to v1.7.0-alpha.1372766adaf8Annotate gloas types for progressive container and field merkleizationdeb157079cInvert config and tests to expect progressive merkleization on by default8cf24656adCommit updated methodical codegen with progressive merkleization flipped to default-on56542829cbEnforce BUILDER_WITHDRAWAL_PREFIX on builder deposit requestsc7adc00b9dReset builder withdrawable epoch on top-up only once swepta9ad3dff90Remove the deposit request bound on Gloas request decoding4f17def149Set BUILDER_WITHDRAWAL_PREFIX to 0xB02afb3af875Reduce Gloas builder config bounds1c2bd3af27Set PAYLOAD_DUE_BPS to 5000126cc7d308Pass the parent slot to Gloas attestation processingca26f14da7Only record early blocks as Gloas equivocation candidatesAcknowledgements
Stack created with GitHub Stacks CLI • Give Feedback 💬