Skip to content

Commit 791395a

Browse files
committed
Use oldest_block_slot to break of pruning payloads
1 parent 7e0cdde commit 791395a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

beacon_node/store/src/hot_cold_store.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2629,7 +2629,7 @@ impl<E: EthSpec, Hot: ItemStore<E>, Cold: ItemStore<E>> HotColdDB<E, Hot, Cold>
26292629
"Pruning finalized payloads";
26302630
"info" => "you may notice degraded I/O performance while this runs"
26312631
);
2632-
let anchor_slot = self.get_anchor_info().anchor_slot;
2632+
let anchor_info = self.get_anchor_info();
26332633

26342634
let mut ops = vec![];
26352635
let mut last_pruned_block_root = None;
@@ -2670,10 +2670,10 @@ impl<E: EthSpec, Hot: ItemStore<E>, Cold: ItemStore<E>> HotColdDB<E, Hot, Cold>
26702670
ops.push(StoreOp::DeleteExecutionPayload(block_root));
26712671
}
26722672

2673-
if slot == anchor_slot {
2673+
if slot < anchor_info.oldest_block_slot {
26742674
info!(
26752675
self.log,
2676-
"Payload pruning reached anchor state";
2676+
"Payload pruning reached anchor oldest block slot";
26772677
"slot" => slot
26782678
);
26792679
break;

0 commit comments

Comments
 (0)