From 6ffd7f4587c28926315db60b0e8ef03da9b5183d Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 17 Feb 2026 21:10:46 +0000 Subject: [PATCH 1/2] Initial plan From 4101360c95283b774f048ea1c242e1b376a4c559 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 17 Feb 2026 21:18:26 +0000 Subject: [PATCH 2/2] Fix MCP registry live test to handle 503 errors gracefully - Add error handling for 503 errors in TestMCPRegistryClient_LiveGetServer - Skip test when registry returns temporary unavailability errors - Add checks for "upstream connect error" and "connection refused" - Improves test resilience against transient registry issues Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com> --- pkg/cli/mcp_registry_live_test.go | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/pkg/cli/mcp_registry_live_test.go b/pkg/cli/mcp_registry_live_test.go index 60df509e19..0ab7713923 100644 --- a/pkg/cli/mcp_registry_live_test.go +++ b/pkg/cli/mcp_registry_live_test.go @@ -138,6 +138,18 @@ func TestMCPRegistryClient_LiveGetServer(t *testing.T) { // Now test GetServer with that name server, err := client.GetServer(serverName) if err != nil { + // Handle 503 errors gracefully - these indicate temporary registry issues + if strings.Contains(err.Error(), "503") || strings.Contains(err.Error(), "upstream connect error") || + strings.Contains(err.Error(), "connection refused") { + t.Skipf("Skipping due to temporary registry unavailability for '%s': %v", serverName, err) + return + } + // Also handle network/firewall issues + if strings.Contains(err.Error(), "network") || strings.Contains(err.Error(), "firewall") || + strings.Contains(err.Error(), "403") || strings.Contains(err.Error(), "connection") { + t.Skipf("Skipping due to network restrictions: %v", err) + return + } t.Fatalf("GetServer failed for '%s': %v", serverName, err) }