Commit bd791d8
authored
Add check that block is known in
Currently,
[on_payload_attestation_message](https://github.com/ethereum/consensus-specs/blob/master/specs/gloas/fork-choice.md#new-on_payload_attestation_message)
raises `KeyError` if `data.beacon_block_root` refers to unknown block.
One consequence is that
[expect_assertion_error](https://github.com/ethereum/consensus-specs/blob/1baa05e71148b0975e28918ac6022d2256b56f4a/tests/core/pyspec/eth_consensus_specs/test/context.py#L385)
won't catch the error.
Historically, block roots are validated with an explicit `assert`. The
PR adds such a check.on_payload_attestation_message (#5022)1 parent 5276545 commit bd791d8
1 file changed
+1
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
853 | 853 | | |
854 | 854 | | |
855 | 855 | | |
| 856 | + | |
856 | 857 | | |
857 | 858 | | |
858 | 859 | | |
| |||
0 commit comments