developing-python

Provide a blueprint for setting up modern Python projects with FastAPI, uv, ruff, mypy, and Docker.

2|2|Updated Feb 9, 2017
One-click install
npx skills add https://github.com/sumik5/dotfiles --skill developing-python
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: developing-python
Source: https://github.com/sumik5/dotfiles/tree/main/claude-code/skills/developing-python
Command: npx skills add https://github.com/sumik5/dotfiles --skill developing-python

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Guides modern Python project development, from FastAPI + FastMCP with DI, to Dockerized environments and robust testing, ensuring scalable Python applications.

Core Features & Use Cases

  • Modern Python stack: uv, ruff, mypy, pydantic, and Docker-focused workflows.
  • Web/API frameworks: FastAPI + FastMCP guidance and DI patterns.
  • Testing & tooling: pytest, linting, type checking, and CI-ready setup.

Quick Start

Start a new Python project or refactor an existing one by following the guide:

  • Initialize a new project: uv init
  • Install dependencies with uv sync --frozen, then set up testing with pytest.

Frequently Asked Questions about developing-python

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I set up a modern Python project with FastAPI and Docker?

Modern Python project setup starts with uv init to scaffold your project, then configure pyproject.toml with FastAPI and FastMCP dependencies. Apply multi-stage Docker builds for containerization, use ruff for linting, mypy for type checking, and pytest for testing to create a production-ready, Cloud Run-compatible stack.

What's the best way to structure a FastAPI application with dependency injection?

Structure FastAPI applications using dependency injection patterns with Pydantic models for request/response validation and FastMCP integration for protocol handling. This approach decouples business logic from routing, improves testability, and aligns with the modern Python stack using strict type checking via mypy.

Can I use uv and ruff together for Python dependency and code management?

Yes. Use uv for fast dependency resolution and runtime management with frozen lock files via uv sync --frozen, and ruff for unified linting and formatting. This combination replaces pip and multiple linting tools, reducing toolchain complexity while maintaining strict code quality standards.

How do I test a Python FastAPI application with pytest?

Test FastAPI applications by writing pytest fixtures that mock dependencies and HTTP clients to verify API endpoints. The modern Python stack provides CI-ready testing strategies that integrate with Docker multi-stage builds, enabling isolated test environments and reliable continuous deployment pipelines.

Does this Python stack work with Google Cloud Run?

Yes. The modern Python project stack is explicitly designed for Cloud Run compatibility through multi-stage Docker builds that optimize container size and startup time. Pair containerization with uv's lightweight runtime and strict type checking to deploy scalable, serverless Python APIs.

What are the limitations of strict type checking with mypy in Python development?

Strict mypy type checking catches runtime errors at development time but requires comprehensive type annotations and may flag legitimate dynamic patterns. The modern Python stack balances strictness with practicality using Pydantic models and FastAPI's built-in type integration to enforce safety without excessive overhead.