docs(time): correct Example Interactions to match server output - #4688
Open
coolrice5 wants to merge 1 commit into
Open
docs(time): correct Example Interactions to match server output#4688coolrice5 wants to merge 1 commit into
coolrice5 wants to merge 1 commit into
Conversation
The example responses in src/time/README.md did not match what the server
actually returns:
- Both examples omitted `day_of_week`, which `TimeResult` declares and the
server always populates via `strftime("%A")`.
- The `convert_time` source showed 12:30 although the request asks for 16:30.
- The target showed `2024-01-01T12:30:00+09:00`, i.e. the conversion had no
effect. New York 16:30 EST is 06:30 the next day in Tokyo.
- `time_difference` read `+13.0h`; EST (-5) to JST (+9) is +14.0h.
- A trailing comma after `time_difference` made the JSON invalid.
Verified against src/time/src/mcp_server_time/server.py.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
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.
The "Example Interactions" responses in
src/time/README.mddon't match what the server actually returns. Verified againstsrc/time/src/mcp_server_time/server.py, whereTimeResultdeclares four fields (timezone,datetime,day_of_week,is_dst).Five issues:
day_of_week, which the server always sets viastrftime("%A").convert_timesource shows12:30though the request asks for16:30.2024-01-01T12:30:00+09:00— the conversion did nothing. New York 16:30 EST is2024-01-02T06:30:00+09:00in Tokyo.time_differencereads+13.0h; EST (-5) to JST (+9) is +14.0h.time_differencemakes the JSON invalid.Documentation only — no code changes.
Credit to @latent-9, who identified these same issues in #4597 and closed that PR themselves.