Skip to content

fix: fall back when server discovery times out - #1149

Open
DaleSeo wants to merge 1 commit into
mainfrom
fix/auto-discover-timeout
Open

fix: fall back when server discovery times out#1149
DaleSeo wants to merge 1 commit into
mainfrom
fix/auto-discover-timeout

Conversation

@DaleSeo

@DaleSeo DaleSeo commented Aug 7, 2026

Copy link
Copy Markdown
Member

Fixes #1142.

Motivation and Context

The 2026-07-28 backward compatibility guidance says that clients should fall back if the server does not respond to server/discover within a reasonable timeout. Previously, discover_startup waited until it received a message or the transport closed.

This PR adds a 10-second timeout to the Auto discovery probe. Explicit Discover startup and legacy initialization remain unchanged. With this change, a connected legacy server that silently ignores server/discover falls back to initialize instead of hanging indefinitely.

How Has This Been Tested?

Added regression tests.

Breaking Changes

None.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update

Checklist

  • I have read the MCP Documentation
  • My code follows the repository's style guidelines
  • New and existing tests pass locally
  • I have added appropriate error handling
  • I have added or updated documentation as needed

@github-actions github-actions Bot added T-documentation Documentation improvements T-core Core library changes T-service Service layer changes labels Aug 7, 2026
@DaleSeo DaleSeo self-assigned this Aug 7, 2026
@DaleSeo
DaleSeo marked this pull request as ready for review August 7, 2026 15:28
@DaleSeo
DaleSeo requested a review from a team as a code owner August 7, 2026 15:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

T-core Core library changes T-documentation Documentation improvements T-service Service layer changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ClientLifecycleMode::Auto hangs on a server that silently ignores server/discover

1 participant