carlos / platform Public

edge flake: TestProbedLocalUpstreamWaitsForReadmission loses a port re-bind race (address already in use) open

Flaky on the CI runner: TestProbedLocalUpstreamWaitsForReadmission (internal/edge/localholdprobedtest.go:139) fails when the re-listen on the upstream's port loses a bind race:

localholdtest.go:197: listen 127.0.0.1:34527: listen tcp 127.0.0.1:34527: bind: address already in use localholdprobed_test.go:139: status = 503 after 1.052488711s (hold 1.05s), want 200 once readmitted

Seen 2026-10-29 19:39Z on design-fleet-secrets-key at 4a1c666b, which changes nothing under internal/edge. The test reopens a fixed port after closing it, and another test or process can take the port in between. Likely fix: retry the listen briefly, or hand the upstream a pre-bound listener.

Same family, different test: TestLoopbackAddrRouteHolds/localhost (internal/edge, localhold_test.go:197) failed on CI for branch managed-fleets-1c-451 (tip dafb5542, 2026-10-30): 'listen 127.0.0.1:39551: bind: address already in use' on re-listen, then 404 at :234. The branch doesn't touch internal/edge.