Skip to content

Conversation

@bryan-anthropic
Copy link
Contributor

Summary

Add minimal documentation for an alternative Python deployment pattern using PyPI and uvx instead of bundling dependencies.

Motivation

During testing, we verified that Python MCP servers can successfully use PyPI for dynamic dependency resolution via uvx. This pattern is already in production use but was undocumented in the MCPB specification.

Changes

README.md

  • Add concise section on PyPI-based deployment
  • Include trade-offs comparison table
  • Link to example implementation

MANIFEST.md

  • Add uvx configuration example alongside traditional Python example

examples/pypi-python/

  • Complete minimal working example
  • Demonstrates manifest and pyproject.toml configuration
  • Shows required [project.scripts] entry point setup

Pattern Overview

Manifest configuration:

{
  "mcp_config": {
    "command": "uvx",
    "args": ["--native-tls", "package-name@latest"]
  }
}

Benefits:

  • Smaller bundle sizes (< 1 MB vs 50+ MB)
  • Automatic updates via @latest tag
  • Modern Python packaging alignment

Trade-offs:

  • Requires users to install uv tool
  • Needs internet connection at first launch

Testing

  • ✅ Verified working with test implementation
  • ✅ Confirmed PyPI package can be fetched via uvx
  • ✅ Validated manifest schema compliance

Documentation Approach

This PR intentionally keeps documentation minimal and generic:

  • No company-specific references in core docs
  • Concise explanations focusing on essentials
  • Working example for reference

bryan-anthropic and others added 2 commits November 13, 2025 09:47
Add comprehensive documentation for:
- Variable substitution patterns for cross-platform portability
- Four-phase testing approach (dev, clean environment, cross-platform, integration)
- Common portability mistakes and solutions
- Error message best practices with actionable examples

These additions help developers create more robust and maintainable MCPB bundles.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <[email protected]>
Add minimal documentation for an alternative Python deployment pattern
using PyPI and uvx instead of bundling dependencies.

Changes:
- README.md: Add concise PyPI deployment section with trade-offs
- MANIFEST.md: Add uvx configuration example
- examples/pypi-python/: Working reference implementation

This pattern enables:
- Smaller bundle sizes (< 1 MB vs 50+ MB)
- Dynamic dependency resolution via PyPI
- Automatic updates with @latest tag

Trade-offs:
- Requires users to install uv tool
- Needs internet connection at first launch

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <[email protected]>
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.

1 participant