From 6668c1a2ee2b70360b49102616dacba81b3fcb49 Mon Sep 17 00:00:00 2001 From: Charles Dusek Date: Fri, 27 Mar 2026 14:27:49 -0500 Subject: [PATCH] p2p/discover: fix flaky TestUDPv5_findnodeHandling Set a very long PingInterval in the UDPv5 test harness to prevent the table's revalidation loop from sending unexpected PING packets through the test pipe. Under the race detector, the test runs slowly enough for the default 3-second revalidation interval to fire, causing background pings to appear as unmatched packets in the pipe queue at close time. Fixes #34108 --- p2p/discover/v5_udp_test.go | 1 + 1 file changed, 1 insertion(+) diff --git a/p2p/discover/v5_udp_test.go b/p2p/discover/v5_udp_test.go index 9429fbaf0a..1c41941c70 100644 --- a/p2p/discover/v5_udp_test.go +++ b/p2p/discover/v5_udp_test.go @@ -937,6 +937,7 @@ func newUDPV5Test(t *testing.T) *udpV5Test { PrivateKey: test.localkey, Log: testlog.Logger(t, log.LvlTrace), ValidSchemes: enode.ValidSchemesForTesting, + PingInterval: 1000 * time.Hour, }) test.udp.codec = &testCodec{test: test, id: ln.ID()} test.table = test.udp.tab