There was an error while loading. Please reload this page.
1 parent d122181 commit 5a67760Copy full SHA for 5a67760
1 file changed
specs/gloas/fork-choice.md
@@ -634,6 +634,16 @@ between *full* and *empty* nodes.
634
def get_head(store: Store) -> ForkChoiceNode:
635
# Get filtered node tree that only includes viable branches
636
filtered_node_tree = get_filtered_node_tree(store)
637
+
638
+ # [New in Gloas:EIP7732]
639
+ if not any(filtered_node_tree):
640
+ # Return empty node if there are no viable nodes
641
+ # to ensure that head is never a pending node
642
+ return ForkChoiceNode(
643
+ root=store.justified_checkpoint.root,
644
+ payload_status=PAYLOAD_STATUS_EMPTY
645
+ )
646
647
# Execute the LMD-GHOST fork-choice
648
head = ForkChoiceNode(
649
root=store.justified_checkpoint.root,
0 commit comments