list changed handlers on client constructor#1206
Merged
KKonstantinov merged 14 commits intomainfrom Dec 4, 2025
Merged
Conversation
commit: |
KKonstantinov
approved these changes
Dec 3, 2025
Contributor
|
See we've extended this PR to add the same functionality for prompts and resources changes. LGTM |
KKonstantinov
requested changes
Dec 3, 2025
Contributor
There was a problem hiding this comment.
@chipgpt's PR was also correlating the server capabilities - tools.listChanged = true.
Likely we should demonstrate this here for tools, resources and prompts listChanged.
Should we also add some checks? It feels odd to allow Clients to listen for the change notifications if the server did not advertise this capability (or explicitly advertised it as listChanged: false?
Contributor
Author
|
adding checks |
Add tests verifying that listChanged handlers are only activated when the server advertises the corresponding capability. Tests cover: - Handler not activated when server lacks listChanged capability - Handler activated when server advertises capability - No handlers activated when server has no listChanged capabilities - Partial capability support with some handlers activated Also defer handler setup until after initialization when server capabilities are known,
This was referenced Dec 4, 2025
sandros06
pushed a commit
to sandros06/inspector
that referenced
this pull request
Dec 25, 2025
Updated implementation to align with the new tools list change behavior introduced in @modelcontextprotocol/sdk v1.25.0 and later. See: modelcontextprotocol/typescript-sdk#1206
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
WIP api design.
Builds off work done by @chipgpt #1068
Motivation and Context
How Has This Been Tested?
Breaking Changes
Types of changes
Checklist
Additional context