prysm-pulse/beacon-chain/state
kasey 1fa864cb1a
use slot:block index correctly (#10820)
* adding splitRoots, refactor to use it

* use splitRoots & work in roots only

the most common use case for this method is to get a list of
candidate roots and check if they are canonical. there isn't a great
reason to look up all the non-canonical blocks, because forkchoice
checks based on the root only, so just return roots and defer the
responsibility of resolving those to full blocks.

* update comment

* clean up shadowing

* more clear non-error return

* add test case for single root in index slot

* fmt

Co-authored-by: Kasey Kirkham <kasey@users.noreply.github.com>
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2022-06-07 16:47:42 +00:00
..
fieldtrie Efficiently Pack Uint64 Lists (#10830) 2022-06-07 06:34:13 +00:00
genesis simplify config names, use strings (#10656) 2022-05-06 21:42:27 +00:00
state-native Clean Up State Finalizer (#10829) 2022-06-06 09:01:58 +00:00
stategen use slot:block index correctly (#10820) 2022-06-07 16:47:42 +00:00
stateutil Efficiently Pack Uint64 Lists (#10830) 2022-06-07 06:34:13 +00:00
testing Deduplicate native state (a.k.a. One State to rule them all) (#10483) 2022-05-09 13:02:34 +00:00
types Deduplicate native state (a.k.a. One State to rule them all) (#10483) 2022-05-09 13:02:34 +00:00
v1 Clean Up State Finalizer (#10829) 2022-06-06 09:01:58 +00:00
v2 Clean Up State Finalizer (#10829) 2022-06-06 09:01:58 +00:00
v3 Clean Up State Finalizer (#10829) 2022-06-06 09:01:58 +00:00
BUILD.bazel Remove Unnecessary State Interfaces (#10707) 2022-05-20 22:40:03 +00:00
error.go Move ErrNilValidatorsInState from one in each state version to a common one (#10074) 2022-01-18 08:19:20 +00:00
interfaces.go Unrealized justification (#10659) 2022-05-27 16:38:00 +00:00
prometheus.go Split state package into state-proto and state-native (#10069) 2022-01-13 12:23:53 +01:00