Skip to content

docs(compliance): Python Pydantic guidance for idempotency_key injection on read tools#4405

Draft
bokelley wants to merge 1 commit into
mainfrom
claude/issue-4399-idempotency-key-read-tool-guidance
Draft

docs(compliance): Python Pydantic guidance for idempotency_key injection on read tools#4405
bokelley wants to merge 1 commit into
mainfrom
claude/issue-4399-idempotency-key-read-tool-guidance

Conversation

@bokelley
Copy link
Copy Markdown
Contributor

Refs #4399

The compliance runner injects idempotency_key on every MCP tool call it dispatches — including read tools like get_products and get_adcp_capabilities. Python sellers using FastMCP or strict Pydantic model validation hit a validation error before their handler runs. This PR adds implementation guidance in the three places Python sellers are most likely to read before or during compliance testing. The normative spec change (sellers MUST NOT use strict MCP parameter validation — a transport-layer MUST) is a 3.1.x item tracked in the issue; this PR ships the workaround guidance that unblocks sellers today.

Non-breaking justification: docs-only addition (MDX pages + empty changeset). No schema changes, no server changes. Existing sellers are unaffected; new Python sellers gain the guidance before hitting the failure.

Pre-PR review:

  • code-reviewer: approved — no blockers; raised error-name precision (fixed: now distinguishes TypeError for function-based dispatch vs ValidationError/extra_forbidden for model-based), Go qualifier (fixed: now scoped to JS/TS with a Go note), and Python 3.9 compat (fixed: Optional[str] with import)
  • docs-expert: approved after blocker fix — Warning originally inside the JS/TS scaffold subsection (wrong audience signal); moved to top of Step 4 where it reaches Python sellers at the right moment (just before they run the storyboard runner)

Shipped in this PR: Known-ambiguities entry, Warning in get-test-ready.mdx (Step 4), Note in build-an-agent.mdx Python tab.

Remaining in #4399: Normative 3.1.x spec addition (sellers MUST use permissive MCP parameter handling — transport-layer MUST). Issue stays open as the tracker for the normative change.

Triage-managed PR. This bot does not currently iterate on
review comments or PR conversation threads (only on the source
issue). To unblock:

  • Push fixup commits directly: gh pr checkout <num>
    fix → push.
  • Or re-trigger: comment /triage execute on the source
    issue.

See #3121
for context.

Session: https://claude.ai/code/session_01AbiTiX3kZd4cGBkeV2Nmgk


Generated by Claude Code

@bokelley bokelley added the claude-triaged Issue has been triaged by the Claude Code triage routine. Remove to re-triage. label May 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

claude-triaged Issue has been triaged by the Claude Code triage routine. Remove to re-triage.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants