Skip to content
Commit 2d4126d2 authored by Adrian Catangiu's avatar Adrian Catangiu Committed by GitHub
Browse files

client/beefy: fix on-demand justifications sync for old blocks (#12767)



* client/beefy: fix on-demand justif sync for old blocks

When receiving BEEFY justifications for old blocks the state might
be pruned for them, in which case justification verification fails
because BEEFY validator set cannot be retrieved from runtime state.

Fix this by having the voter give the validator set to the
`OnDemandJustificationsEngine` as request information. On receiving
a BEEFY justification for requested block, the provided validator
set will be used to validate the justification.

Signed-off-by: default avataracatangiu <[email protected]>

* Apply suggestions from code review

Co-authored-by: default avatarBastian Köcher <[email protected]>

* impl review suggestions

* client/beefy: fail initialization if state unavailable

* beefy: remove spammy log

Signed-off-by: default avataracatangiu <[email protected]>
Co-authored-by: parity-processbot <>
Co-authored-by: default avatarBastian Köcher <[email protected]>
parent 0c934a93
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment