From 15dbd081605dc65ce7caeb40eb17f9e5884e7aeb Mon Sep 17 00:00:00 2001 From: Michael Sproul Date: Thu, 5 Dec 2024 16:31:04 +1100 Subject: [PATCH] Stuck lookup v6 (#6658) Squashed commit of the following: commit 193c7f82411bb7c28cec1959e2d7682d72d1452b Author: dapplion <35266934+dapplion@users.noreply.github.com> Date: Thu Dec 5 09:32:57 2024 +0800 Fix stuck lookups if no peers on v6 --- .../network/src/sync/block_lookups/single_block_lookup.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/beacon_node/network/src/sync/block_lookups/single_block_lookup.rs b/beacon_node/network/src/sync/block_lookups/single_block_lookup.rs index d701cbbb8d3..9bbd2bf295b 100644 --- a/beacon_node/network/src/sync/block_lookups/single_block_lookup.rs +++ b/beacon_node/network/src/sync/block_lookups/single_block_lookup.rs @@ -171,7 +171,10 @@ impl SingleBlockLookup { self.awaiting_parent.is_some() || self.block_request_state.state.is_awaiting_event() || match &self.component_requests { - ComponentRequests::WaitingForBlock => true, + // If components are waiting for the block request to complete, here we should + // check if the`block_request_state.state.is_awaiting_event(). However we already + // checked that above, so `WaitingForBlock => false` is equivalent. + ComponentRequests::WaitingForBlock => false, ComponentRequests::ActiveBlobRequest(request, _) => { request.state.is_awaiting_event() }