Implement tree states & hierarchical state DB

This commit is contained in:
Michael Sproul
2023-06-19 10:14:47 +10:00
parent 2bb62b7f7d
commit 23db089a7a
193 changed files with 6093 additions and 5925 deletions

View File

@@ -219,7 +219,7 @@ impl InvalidPayloadRig {
let mock_execution_layer = self.harness.mock_execution_layer.as_ref().unwrap();
let head = self.harness.chain.head_snapshot();
let state = head.beacon_state.clone_with_only_committee_caches();
let state = head.beacon_state.clone();
let slot = slot_override.unwrap_or(state.slot() + 1);
let (block, post_state) = self.harness.make_block(state, slot).await;
let block_root = block.canonical_root();
@@ -312,7 +312,7 @@ impl InvalidPayloadRig {
self.harness
.chain
.store
.get_full_block(&block_root)
.get_full_block(&block_root, None)
.unwrap()
.unwrap(),
block,
@@ -2013,7 +2013,7 @@ async fn weights_after_resetting_optimistic_status() {
.fork_choice_read_lock()
.get_block_weight(&head.head_block_root())
.unwrap(),
head.snapshot.beacon_state.validators()[0].effective_balance,
head.snapshot.beacon_state.validators().get(0).unwrap().effective_balance(),
"proposer boost should be removed from the head block and the vote of a single validator applied"
);