diff --git a/specs/core/0_fork-choice.md b/specs/core/0_fork-choice.md index 8e25fe8f3..552a3cb02 100644 --- a/specs/core/0_fork-choice.md +++ b/specs/core/0_fork-choice.md @@ -192,8 +192,7 @@ def on_attestation(store: Store, attestation: Attestation) -> None: # Attestations can only affect the fork choice of subsequent slots. # Delay consideration in the fork choice until their slot is in the past. - attestation_slot = attestation.data.slot - assert store.time >= (attestation_slot + 1) * SECONDS_PER_SLOT + assert store.time >= (attestation.data.slot + 1) * SECONDS_PER_SLOT # Get state at the `target` to validate attestation and calculate the committees indexed_attestation = get_indexed_attestation(target_state, attestation) diff --git a/specs/validator/0_beacon-chain-validator.md b/specs/validator/0_beacon-chain-validator.md index 331184699..1be028df4 100644 --- a/specs/validator/0_beacon-chain-validator.md +++ b/specs/validator/0_beacon-chain-validator.md @@ -285,6 +285,11 @@ First, the validator should construct `attestation_data`, an [`AttestationData`] - Let `head_block` be the result of running the fork choice during the assigned slot. - Let `head_state` be the state of `head_block` processed through any empty slots up to the assigned slot using `process_slots(state, slot)`. +##### General + +* Set `attestation_data.slot = slot` where `slot` is the assigned slot. +* Set `attestation_data.index = index` where `index` is the index associated with the validator's committee. + ##### LMD GHOST vote Set `attestation_data.beacon_block_root = signing_root(head_block)`. @@ -299,10 +304,6 @@ Set `attestation_data.beacon_block_root = signing_root(head_block)`. - Let `start_slot = compute_start_slot_of_epoch(get_current_epoch(head_state))`. - Let `epoch_boundary_block_root = signing_root(head_block) if start_slot == head_state.slot else get_block_root(state, start_slot)`. -##### Index - -Set `attestation_data.index = index` where `index` is the index associated with the validator's committee. - #### Construct attestation Next, the validator creates `attestation`, an [`Attestation`](../core/0_beacon-chain.md#attestation) object.