EIP-7917 · Final · Core · 2025-03-24
EIP-7917: Deterministic proposer lookahead
Stores the next epochs' block-proposer schedule in the beacon state at each epoch boundary, making the lookahead fully deterministic and provable to smart contracts.
What problem does it solve?
On the beacon chain, block proposers are chosen pseudo-randomly from a RANDAO seed, weighted by each validator's effective balance. The seed for epoch N + 1 is known one epoch early, but effective balances can still change during epoch N (slashings, penalties and, since EIP-7251, rewards, deposits and consolidations above 32 ETH). So the proposer schedule for the next epoch was not actually fixed until that epoch started.
That matters for based preconfirmation protocols, which need to know reliably who will propose upcoming blocks. It also left room, at least in theory, for validators to tune their balances after seeing the RANDAO output to influence the schedule.
How it works
BeaconStategains a fieldproposer_lookahead: a vector of validator indices covering(MIN_SEED_LOOKAHEAD + 1) * SLOTS_PER_EPOCHslots, i.e. the current epoch plus the next one with today's parameters.get_beacon_proposer_indexsimply readsproposer_lookahead[slot % SLOTS_PER_EPOCH]instead of computing the proposer on demand.- At every epoch boundary, the first epoch's entries are shifted out and the proposers for the newest epoch are computed and appended.
- At the fork, the first block fills the whole vector.
Effective balances used for an epoch's schedule are now the ones at the start of epoch N - MIN_SEED_LOOKAHEAD, aligned with when the RANDAO seed becomes known. The randomness delay itself is unchanged.
Because the lookahead lives in the beacon state, a contract can verify the upcoming proposers against the beacon block root exposed by EIP-4788 with a Merkle proof.
Sample code
The epoch-boundary update, from the spec (Python, consensus-specs style):
def process_proposer_lookahead(state: BeaconState) -> None:
last_epoch_start = len(state.proposer_lookahead) - SLOTS_PER_EPOCH
# Shift out proposers in the first epoch
state.proposer_lookahead[:last_epoch_start] = state.proposer_lookahead[SLOTS_PER_EPOCH:]
# Fill in the last epoch with new proposer indices
last_epoch_proposers = get_beacon_proposer_indices(
state, Epoch(get_current_epoch(state) + MIN_SEED_LOOKAHEAD + 1)
)
state.proposer_lookahead[last_epoch_start:] = last_epoch_proposers
def get_beacon_proposer_index(state: BeaconState) -> ValidatorIndex:
return state.proposer_lookahead[state.slot % SLOTS_PER_EPOCH]
Indexing: proposer_lookahead[0] is the first proposer of the current epoch; proposer_lookahead[SLOTS_PER_EPOCH + 4] is the fifth proposer of the next epoch.
Things to know
- Status: Final. It is part of the Fulu consensus-layer specs (the consensus side of the Fusaka upgrade).
- It changes no execution-layer behaviour and no user-facing transactions. The visible changes are a new beacon-state field and a guaranteed next-epoch proposer schedule.
- Clients now compute a whole epoch of proposers at each boundary instead of one per slot. This is cheap, but it is extra work at the epoch transition.
- The authors note that a future Single Secret Leader Election design could reuse the field (e.g. as encrypted indices) or leave it empty, so it does not block SSLE.