Skip to content

MCP: tell the --output format switch apart from an --output path; ship LICENSE in every wheel - #25

Merged
alpibrupa merged 1 commit into
mainfrom
claude/review-books-bootcamps-35csth
Sep 1, 2026
Merged

MCP: tell the --output format switch apart from an --output path; ship LICENSE in every wheel#25
alpibrupa merged 1 commit into
mainfrom
claude/review-books-bootcamps-35csth

Conversation

@alpibrupa

Copy link
Copy Markdown
Contributor

What

Closes #21, closes #22.

MCP adapter

_catalog.py treated any option named --output as the text|json format flag: it hid it from the tool's input schema and appended --output json to every invocation. For bookkit write outline and bookkit write chapter, --output is the destination path (type: path in the CLI's own introspect), so the outline was written to a file literally named json, the chapter to ./json, and the model never received a JSON envelope.

The format switch is now recognised by its type (an enum[...] containing json) rather than its name, via _is_format_option(). A path-typed --output is exposed as an ordinary parameter and passed through. The test catalog's write outline entry now carries the path type the real CLI declares; test_path_typed_output_option_is_a_real_parameter covers the argv with and without a path, and the existing group-command test asserts no --output json is appended.

Licence files

Each package declares license = "EUPL-1.2" but had no LICENSE file in its own directory, so hatchling shipped none (License-File: None, empty licenses/ in every built wheel). A copy of the repository LICENSE now sits in each package root, which hatchling's default license-file glob picks up. Verified by building all four wheels:

bookkit-0.1.0-py3-none-any.whl            bookkit-0.1.0.dist-info/licenses/LICENSE
content_kit_core-0.1.0-py3-none-any.whl   content_kit_core-0.1.0.dist-info/licenses/LICENSE
content_kit_mcp-0.1.0-py3-none-any.whl    content_kit_mcp-0.1.0.dist-info/licenses/LICENSE
podcastkit-0.1.0-py3-none-any.whl         podcastkit-0.1.0.dist-info/licenses/LICENSE

packages/bookkit/README.md's [LICENSE](LICENSE) link now resolves.

Verification

ruff check packages, ruff format --check packages, pytest packages/mcp (12 passed).

🤖 Generated with Claude Code

https://claude.ai/code/session_01GexXknLn75PzvBJRG3MDFW


Generated by Claude Code

…p LICENSE in every wheel

_catalog.py treated any option named --output as the text|json format
flag: it hid it from the tool schema and appended "--output json" to
every invocation. For `bookkit write outline` and `write chapter` that
option is the destination path, so the outline was written to a file
literally named "json" and the model never got an envelope. The format
switch is now recognised by its type (an enum containing "json"), and a
path-typed --output is exposed as an ordinary parameter. The test
catalog's write outline entry now carries the path type the real
introspect declares; a test covers the argv both without and with a
path.

Each package declares license = "EUPL-1.2" but had no LICENSE file in
its own directory, so hatchling shipped none (License-File: None in
every built wheel). A copy of the repository LICENSE now sits in each
package root, which hatchling's default license-file glob picks up;
verified by building all four wheels.

Closes #21, closes #22.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GexXknLn75PzvBJRG3MDFW
@alpibrupa
alpibrupa marked this pull request as ready for review September 1, 2026 23:32
@alpibrupa
alpibrupa merged commit 141b93c into main Sep 1, 2026
4 checks passed
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.

No licence text ships in any package wheel MCP adapter treats the --output path of write outline / write chapter as the JSON-format flag

1 participant