Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow setting the timeout with the "timeout" URL parameter #100

Merged
merged 1 commit into from
Dec 5, 2024

Conversation

evalstate
Copy link
Contributor

@evalstate evalstate commented Dec 4, 2024

Allows setting the Request Timeout in milliseconds with a "timeout" URL parameter

Motivation and Context

Enables testing of tools which take > 10s to respond.

How Has This Been Tested?

This has been tested using the mcp-everything server

image

Breaking Changes

No breaking changes.

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

Additional context

@ashwin-ant this is intended to cover simple cases - I considered matching progress updates to requestids to reset the timer - but that seems over-engineered for the need.

ashwin-ant
ashwin-ant previously approved these changes Dec 4, 2024
Copy link
Member

@ashwin-ant ashwin-ant left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@evalstate
Copy link
Contributor Author

Build failing - think it is related to this commit in the SDK:

modelcontextprotocol/typescript-sdk@e911ece

Will fix.

@ashwin-ant
Copy link
Member

@evalstate I have a PR open to update the SDK #101

@evalstate
Copy link
Contributor Author

evalstate commented Dec 4, 2024

OK. I've added a commit - I'll wait for your PR to go through and merge. Best.

@jspahrsummers
Copy link
Member

Sorry about the breakage here! Per discussion on #101, didn't mean to release this breaking change—working on fixing it up now 😟

@ashwin-ant
Copy link
Member

@evalstate I've updated the SDK to 1.0.3, mind rebasing this PR (and removing the second commit)?

@evalstate evalstate reopened this Dec 5, 2024
@evalstate
Copy link
Contributor Author

Rebased; commits tidied.

@ashwin-ant ashwin-ant merged commit 18dc4d0 into modelcontextprotocol:main Dec 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants