[project] name = "rancher-mcp" version = "1.64.0" description = "Capability-aware MCP server for Rancher-managed Kubernetes: discovery, generic resource access, and curated operator workflows across the Norman and Steve planes (Rancher 2.6.5–2.9.3)" readme = "README.md" license = "MIT" license-files = ["LICENSE"] authors = [{ name = "Pierce Moore", email = "pierce@piercemoore.com" }] keywords = ["mcp", "model-context-protocol", "rancher", "kubernetes", "k8s", "devops", "sre", "llm", "agent"] classifiers = [ "Development Status :: 5 - Production/Stable", "Intended Audience :: System Administrators", "Intended Audience :: Developers", "Operating System :: OS Independent", "Programming Language :: Python :: 3.12", "Programming Language :: Python :: 3.13", "Topic :: System :: Systems Administration", "Topic :: Software Development :: Libraries :: Python Modules", ] requires-python = ">=3.12" dependencies = [ "httpx>=0.28.1", # UPPER BOUND IS LOAD-BEARING — do not widen without porting the server. # `mcp` 2.0.0 (2026-07-28) implements protocol revision 2026-07-28 and # REMOVED the `fastmcp` module entirely: `FastMCP` is now `MCPServer`, and # `mcp.server.fastmcp` does not exist. This package imports `FastMCP` in 40 # source files, so an unbounded constraint means a fresh resolve installs # 2.0.0 and the server dies with ImportError before it can serve anything. # That is not hypothetical: `>=1.0` shipped in 1.26.4 and broke every # `uvx rancher-mcp` / `pip install rancher-mcp` from 2026-07-28 onward, # because a lockfile only protects this repo, never a downstream install. # Enforced by tests/unit/test_dependency_constraints.py. "mcp[cli]>=1.26,<2", "pydantic>=2.12.5", "pydantic-settings>=2.13.1", "pyyaml>=6.0.3", "structlog>=25.5.0", "tenacity>=9.1.4", "websockets>=16.0", ] [project.urls] Homepage = "https://github.com/rex/mcp-rancher" Repository = "https://github.com/rex/mcp-rancher" Changelog = "https://github.com/rex/mcp-rancher/blob/main/CHANGELOG.md" Issues = "https://github.com/rex/mcp-rancher/issues" [project.scripts] rancher-mcp = "rancher_mcp.__main__:main" [build-system] requires = ["uv_build>=0.9.26,<0.10.0"] build-backend = "uv_build" [dependency-groups] dev = [ "jinja2>=3.1", "pre-commit>=4.5.1", "pyright>=1.1.408", "pytest>=9.0.2", "pytest-asyncio>=1.3.0", "pytest-cov>=7.1.0", "respx>=0.22.0", "ruff>=0.15.8", ] [tool.ruff] target-version = "py312" line-length = 100 extend-exclude = [".claude/worktrees"] [tool.ruff.format] # Vendored agentic-skeleton gate scripts are synced verbatim by # scripts/sync_skeleton.py; the repo formatter must not rewrite them # (that would create skeleton drift the next --check flags). They stay # under `ruff check` via per-file-ignores below — only formatting is # exempt. All repo-authored scripts are still formatted normally. exclude = [ "scripts/bump_version.py", "scripts/check_architecture.py", "scripts/check_docs.py", "scripts/check_module_rules.py", "scripts/check_skills.py", "scripts/check_version_bumped.py", "scripts/stamp_skill.py", "scripts/sync_skeleton.py", ] [tool.ruff.lint] select = ["E", "W", "F", "I", "B", "C4", "UP", "SIM", "TID", "ANN", "S", "LOG"] ignore = ["ANN401"] [tool.ruff.lint.per-file-ignores] "tests/**" = ["S101", "S105", "S106"] "src/**/_generated_*.py" = ["E501"] # Vendored agentic-skeleton gate scripts (synced verbatim by # scripts/sync_skeleton.py — editing them creates skeleton drift). They # are PEP-723 `uv run --script` tools that shell out to git, so they # trip S603/S607 (trusted, hardcoded argv) and carry the skeleton's own # import ordering. Scope the exemption to these files and exactly those # rules; all repo-authored scripts keep the full profile. "scripts/bump_version.py" = ["S603", "S607", "I001", "SIM108"] "scripts/check_architecture.py" = ["S603", "S607", "I001"] "scripts/check_docs.py" = ["S603", "S607", "I001"] "scripts/check_module_rules.py" = ["S603", "S607", "I001"] "scripts/check_skills.py" = ["S603", "S607", "I001", "E501"] "scripts/check_version_bumped.py" = ["S603", "S607", "I001"] "scripts/stamp_skill.py" = ["S603", "S607", "I001", "E501"] "scripts/sync_skeleton.py" = ["S603", "S607", "I001"] [tool.pyright] pythonVersion = "3.12" typeCheckingMode = "strict" reportMissingTypeStubs = false venvPath = ".venv" # Vendored agentic-skeleton gate scripts are synced verbatim by # scripts/sync_skeleton.py and are not authored to this repo's strict # pyright profile; editing them to satisfy it would create skeleton # drift. Exempt only these files — all repo-authored code under # scripts/ stays fully type-checked. exclude = [ "scripts/bump_version.py", "scripts/check_architecture.py", "scripts/check_docs.py", "scripts/check_module_rules.py", "scripts/check_skills.py", "scripts/check_version_bumped.py", "scripts/stamp_skill.py", "scripts/sync_skeleton.py", ] [tool.pytest.ini_options] asyncio_mode = "auto" testpaths = ["tests"] addopts = "--cov=src --cov-report=term-missing --cov-fail-under=60" [tool.coverage.run] omit = ["tests/*"]