Description
#9675 added SYNC_MESSAGE_DUE_BPS_GLOAS and a fork-aware ChainSpec::get_sync_message_due_at_slot, but only the VC consumes it. Three BN call sites still use the fork-blind get_sync_message_due():
|
let sync_message_due = chain.spec.get_sync_message_due(); |
and
|
let sync_message_due = chain.spec.get_sync_message_due(); |
- the TooEarly gossip gates. The spec defines these via get_sync_message_due_ms(), which Gloas modifies. Post-Gloas we would reject light client updates from spec-compliant peers arriving between 25% and 33.33% of the slot, and downscore them.
|
spec.get_sync_message_due(), |
- grades sync message delay against the pre-Gloas due point. Metrics only.
Harmless today since GLOAS_FORK_EPOCH is far-future in every config.
Steps to resolve
Switch the three call sites to get_sync_message_due_at_slot, using the update's signature_slot for the light client gates and the message's slot in the validator monitor. I think signature_slot is the right fork selector since the gate measures time from the start of that slot, but a test at the fork boundary would pin it down.
Once wired, get_sync_message_due() has no production callers and can be removed, renaming get_sync_message_due_at_slot to get_sync_message_due::<E>(slot) to match get_attestation_due.
Additional Info
Part of the broader inner-slot timing work in #8615.
Description
#9675 added
SYNC_MESSAGE_DUE_BPS_GLOASand a fork-awareChainSpec::get_sync_message_due_at_slot, but only the VC consumes it. Three BN call sites still use the fork-blindget_sync_message_due():lighthouse/beacon_node/beacon_chain/src/light_client_optimistic_update_verification.rs
Line 74 in 1cd1a3c
lighthouse/beacon_node/beacon_chain/src/light_client_finality_update_verification.rs
Line 78 in 1cd1a3c
TooEarlygossip gates. The spec defines these viaget_sync_message_due_ms(), which Gloas modifies. Post-Gloas we would reject light client updates from spec-compliant peers arriving between 25% and 33.33% of the slot, and downscore them.lighthouse/beacon_node/beacon_chain/src/validator_monitor.rs
Line 1539 in 1cd1a3c
Harmless today since
GLOAS_FORK_EPOCHis far-future in every config.Steps to resolve
Switch the three call sites to
get_sync_message_due_at_slot, using the update'ssignature_slotfor the light client gates and the message's slot in the validator monitor. I thinksignature_slotis the right fork selector since the gate measures time from the start of that slot, but a test at the fork boundary would pin it down.Once wired,
get_sync_message_due()has no production callers and can be removed, renamingget_sync_message_due_at_slottoget_sync_message_due::<E>(slot)to matchget_attestation_due.Additional Info
Part of the broader inner-slot timing work in #8615.