Conversation
|
This PR has been closed automatically. It's still a draft, but we close those early so you don't put in more time only to have it closed the moment you mark it ready. This repo only keeps pull requests open when they come from a maintainer, or from a contributor a maintainer has assigned to the linked issue, and this PR doesn't link an open issue yet.
You're welcome to keep pushing commits here (just avoid force-pushing, since GitHub can't reopen a rewritten branch), but that on its own won't get the PR reviewed or the issue assigned, and realistically most auto-closed PRs stay closed. There's no need to open a new PR either way. CONTRIBUTING.md has the full reasoning, but in short:
Maintainers: reopen, remove |
Related to #3637. This draft clarifies the current contract; it does not implement either proposed runtime behavior or close the issue.
Motivation and Context
A tool accepting
book: Bookexpects{"book": {...}}; passingbook.model_dump()as the whole arguments object does not bind that parameter. Document the correct call shape, explain defaults and model extension fields, and point applications requiring flat wire arguments to the existing low-levelServerAPI.Strengthen the model-parameter schema snapshot and add a public
Clientround-trip test covering a defaulted model, nested extension fields, and the current behavior when model fields are sent flat.Implicit flattening or accepting both shapes remains a maintainer design decision. Standalone FastMCP 4.0.3 reproduces the reported
unexpected_keyword_argument; SDK 2.x instead ignores unmatched flat fields when the model parameter has a default. This draft preserves SDK behavior.How Has This Been Tested?
uv run --frozen pytest tests/docs_src/test_tools.py tests/interaction/mcpserver/test_tools.py -q— 90 passed, including public client/server round trips and existing transport/protocol coverage.uv run --frozen pyright— 0 errors.git diff --checkpassed.Breaking Changes
None. Documentation and regression coverage only; no runtime API changes.
Types of changes
Checklist
help wanted, or I'm a maintainer)Additional context
AI assistance: prepared with Codex. Human review remains pending; the AI-accountability checkbox is intentionally unchecked. Error-handling changes are not applicable to this documentation/test draft.
At creation, #3637 is unassigned and lacks
help wanted. The contribution gate is unmet and the intake bot may close this draft. No maintainer assignment or approval is implied.