From fc99f5c3234449c9193c6d2ba49e70d119587ab7 Mon Sep 17 00:00:00 2001 From: gop Date: Wed, 6 Sep 2023 12:47:21 -0500 Subject: [PATCH] bugfix: If you dont have a peer from the specific location, ask for pending etx from random peer --- eth/handler.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/eth/handler.go b/eth/handler.go index 0b338cad5a..65f49c4b34 100644 --- a/eth/handler.go +++ b/eth/handler.go @@ -532,6 +532,12 @@ func (h *handler) missingPendingEtxsLoop() { log.Trace("Fetching the missing pending etxs from", "peer", peer.ID(), "hash", hashAndLocation.Hash) peer.RequestOnePendingEtxs(hashAndLocation.Hash) } + if len(peersRunningSlice) == 0 { + for _, peer := range h.selectSomePeers() { + log.Trace("Fetching the missing pending etxs from", "peer", peer.ID(), "hash", hashAndLocation.Hash) + peer.RequestOnePendingEtxs(hashAndLocation.Hash) + } + } case <-h.missingPendingEtxsSub.Err(): return }