Skip to content

fix(mcp): use spec-accurate read-only annotations - #335

Merged
dodeja merged 1 commit into
mainfrom
cursor/fix-mcp-readonly-annotations-0a38
Aug 21, 2026
Merged

fix(mcp): use spec-accurate read-only annotations#335
dodeja merged 1 commit into
mainfrom
cursor/fix-mcp-readonly-annotations-0a38

Conversation

@dodeja

@dodeja dodeja commented Aug 21, 2026

Copy link
Copy Markdown
Member

Summary

  • mark the nine fetch-only Terminal49 MCP tools with readOnlyHint: true
  • keep track_container non-read-only, non-destructive, private-account-only, and non-idempotent
  • align server instructions, protocol coverage, and ChatGPT listing justifications with the MCP semantics

Rationale

The Claude directory validates MCP tool annotations according to the protocol. Emitting redacted operational logs does not make a fetch-only tool a write, so the prior all-false annotation set was inaccurate.

Testing

  • npm run test --workspace @terminal49/mcp -- --run (182 tests)
  • npm run build --workspace @terminal49/mcp
  • NODE_OPTIONS=--experimental-strip-types npm run lint --workspace @terminal49/mcp
  • parsed chatgpt-app-submission.json with Node.js JSON parser
Open in Web Open in Cursor 

View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.

Greptile Summary

This PR corrects MCP metadata so nine fetch-only tools are declared read-only while track_container remains the sole write operation.

  • Aligns runtime tool annotations and server instructions with MCP semantics.
  • Updates protocol and registration tests to enforce the read/write boundary.
  • Synchronizes the ChatGPT submission metadata and justifications with runtime behavior.

Confidence Score: 5/5

The PR appears safe to merge because the reclassified tools only execute read operations and the sole account-mutating tool remains explicitly non-read-only.

Runtime registration, protocol coverage, submission metadata, and actual handler behavior consistently preserve the boundary between nine fetch-only tools and track_container.

Important Files Changed

Filename Overview
packages/mcp/src/server.ts Reclassifies nine read-only tools consistently while preserving track_container as a non-read-only write operation.
packages/mcp/src/annotations.test.ts Splits fetch-only and write-tool expectations and continues checking annotations across every registered tool.
packages/mcp/src/protocol-compat.test.ts Updates protocol-level assertions to derive read-only status from whether the tool is track_container.
chatgpt-app-submission.json Synchronizes directory-submission annotations and justifications with the runtime tool semantics.

Reviews (1): Last reviewed commit: "fix(mcp): correct read-only tool annotat..." | Re-trigger Greptile

Co-authored-by: Akshay Dodeja <dodeja@gmail.com>
@vercel

vercel Bot commented Aug 21, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
api Ready Ready Preview Aug 21, 2026 5:02am

Request Review

@dodeja
dodeja marked this pull request as ready for review August 21, 2026 05:15
@dodeja
dodeja merged commit 663ffe3 into main Aug 21, 2026
23 checks passed
@vorflux

vorflux Bot commented Aug 21, 2026

Copy link
Copy Markdown

Summary

Reviewed the MCP tool annotation changes that mark nine fetch/list/search operations as read-only while keeping track_container classified as a write. The protocol tests, annotation tests, server instructions, and chatgpt-app-submission.json remain consistent with the runtime annotations.

Verdict

Reviewed — no issues found. The annotations accurately reflect the tools' behavior, with no actionable bugs, security concerns, breaking changes, or concurrency issues identified.

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.

2 participants