Skip to main content

PyPI version Python versions CI codecov License: MIT Ruff uv Conventional Commits

Py Launch Blueprint: A Production-Ready 🐍 Python Project Template with Integrated Best Practices

Py Launch Blueprint is a comprehensive Python project template that eliminates setup friction by providing a pre-configured development environment with carefully selected tools for linting, formatting, and type checking. It includes an annotated CLI example and detailed documentation explaining each tool choice and configuration decision, making it an ideal starting point for professional Python projects.

Py Launch Blueprint Logo

Why Choose Py Launch Blueprint?

Py Launch Blueprint eliminates the setup friction in Python projects by providing a production-ready template with carefully curated tools and best practices.

Full documentation on ReadTheDocs

🚀 Key Features

Zero-config development environment with type safety built in.

✨ Features TLDR

  • 🛠️ Dev Tools: Ruff (linting/formatting), ty (type checking, Astral), lefthook (hooks), commitlint
  • 🔒 Security: gitleaks (commit/push), TruffleHog (CI), bandit (pre-push + CI), CodeQL
  • 🧠 AI Ready: AGENTS.md as the single canonical agent config (CLAUDE.md imports it; Cursor, Windsurf, Codex read it natively) + a project-bootstrap skill
  • 💪 Production: Python 3.13+, uv + uv_build, PEP 735 dependency-groups, static version
  • 🚀 DX - Developer Experience: VS Code DevContainer, sensible defaults, quality documentation
  • 🔄 CI/CD: GitHub Actions workflows, release-please version bumps, OIDC trusted publishing

Quick start

git clone https://github.com/smorinlabs/py-launch-blueprint.git
cd py-launch-blueprint
make bootstrap           # level 1 — base toolchain (just + uv); skip if installed
just setup               # level 2 — dev env, git hooks, hook toolchain
just check               # full quality pipeline

Install as a tool: uvx --from py-launch-blueprint plbp (uvx needs --from because the distribution name differs from the console-script name) or pip install py-launch-blueprint && plbp.

The plbp noun-verb CLI documents the template's CLI conventions: global flags, the text/JSON/Markdown output contract, stable exit & error codes, and layered TOML config.

See AGENTS.md for the canonical command set, .github/CONTRIBUTING.md for the daily workflow, and docs/RELEASE.md for the release flow. For the exhaustive rationale behind every tool and configuration choice — what each is, why it was chosen, and the value it brings — see Design Decisions.

Web service (FastAPI)

The blueprint includes an optional REST API (uv sync --extra web, just serve) with production best practices already baked in: RFC 9457 problem+json errors, /v1 versioning, pagination, Idempotency-Key replay, Prometheus metrics, opt-in OpenTelemetry tracing, rate limiting, security headers, typed env settings, a committed OpenAPI snapshot with breaking-change CI (oasdiff) and schemathesis fuzzing, generated typed clients, and a production Dockerfile. See EXAMPLEWEB.md for the service walkthrough (the web counterpart of EXAMPLECLI.md), the web service docs, the WEB-xx convention catalog, and ADR 0013 for the design decisions.

Stable GitHub releases also publish a linux/amd64 container to ghcr.io/smorinlabs/py-launch-blueprint. Availability begins with the first release containing this workflow and completion of the public-package setup. Once available, run the web service locally:

docker pull --platform linux/amd64 ghcr.io/smorinlabs/py-launch-blueprint:latest
docker run --rm --platform linux/amd64 -p 127.0.0.1:8000:8000 ghcr.io/smorinlabs/py-launch-blueprint:latest

The health endpoint is http://127.0.0.1:8000/healthz. Each release also has an X.Y.Z image tag matching its version. Use the sha256 digest recorded in the publishing workflow's summary when a deployment must select exact image bytes. Public images can be pulled without signing in.

Starting a new project from this template? If you use Claude Code or any agent that reads AGENTS.md, just say "create a new Python project from py-launch-blueprint" — the new-python-project skill (Claude Code discovers it in .claude/skills/; Codex via the .agents/skills/ symlink) will walk you through gh repo create --template, identity collection, and the press rebrand (uv run --locked press rebrand, dry-run preview first). For humans without an agent: the skill is also a copy-pasteable runbook. After the press, work through docs/PROJECT_SETUP.md — the checklist of decisions, secrets, and repo settings to configure. Internal engineering docs (ADRs, design specs, research) live under docs/.

🎯 Perfect For

Teams and professionals needing maintainable, type-safe Python projects following best practices.

Complete Feature List

Development Tools

  • Bootstrap dependency check and install with make: Execute common development tasks with simple commands, standardizing workflows across team members.

  • Optional one-command toolchains with mise or flox: mise install (root mise.toml) or flox activate (root .flox/) provisions the same 11-tool set as the native installers — pick whichever fits your machine; see ADR 0005.

  • Command running with just: Define and run project-specific commands with a modern Make alternative, simplifying complex operations with clear syntax.

  • Linting with ruff: Catch errors and enforce code style at lightning speed (10-100x faster than traditional linters), reducing waiting time and improving developer productivity.

  • Type checking with ty: Prevent type-related bugs before they occur with Astral's fast Rust-based type checker, making your codebase more robust and easier to maintain as it grows.

  • Formatting with ruff: Ensure consistent code style across your project automatically, eliminating style debates and pull request revision cycles.

  • Git hooks with lefthook: Enforce quality standards before code enters your repository (secret scanning, linting, commit-message checks at commit/push), preventing bad code from ever being committed and reducing technical debt.

  • TOML formatting and validation with taplo: Verify Toml files for syntax correctness, maintain consistent configuration files, ensuring readability and avoiding syntax errors in critical project settings.

  • YAML validation with yamllint: Verify YAML files for syntax correctness, preventing configuration errors and deployment failures.

Project Structure & Management

  • Project configuration with pyproject.toml: Organize all project settings in one standardized location, simplifying maintenance and configuration.

  • Dependency groups separation: Organize dependencies into main, dev, and doc categories, preventing bloated installations and clarifying requirements as part of pyproject.toml configuration.

  • Dependency management with uv: Install and manage packages at blazing speed (100x faster than pip/poetry), dramatically reducing environment setup time.

  • Build system with uv_build: Build wheel and source distributions with uv's build backend and uv build.

  • Versioning with explicit project metadata: Keep release tags aligned with the static version in pyproject.toml for predictable package metadata.

  • Copyright license automation: Automatically add license headers to all files, ensuring legal compliance without manual effort.

Documentation

  • Documentation with sphinx + MyST: Generate comprehensive documentation that supports both reStructuredText and Markdown, improving contributor accessibility.

  • Read the Docs integration: Deploy documentation automatically, providing instant hosting and versioning for your project's documentation.

  • Changelog management with release-please: Generate the changelog and version bumps automatically from Conventional Commits, improving project transparency and adoption.

Testing & Quality Assurance

  • Testing framework with pytest: Write and run tests with a modern, powerful testing framework that supports fixtures and parameterization.

  • CI/CD with GitHub Actions: Automatically test, build, and deploy your project on multiple Python versions, catching compatibility issues early.

  • Matrix testing with GitHub Actions: Run tests across multiple Python versions and operating systems, ensuring broad compatibility.

  • Simplified debugging info with just debug-info: Automatically collect and format essential system, tool, and dependency information for streamlined bug reporting via a simple command.

GitHub Integration

  • Pull request template: Guide contributors through the PR process with structured information requirements, improving submission quality.

  • Issue templates (Feature, Bug, Documentation): Standardize issue reporting with appropriate fields for each type, gathering all necessary information upfront.

  • Automated contributor recognition with contributors-please: Automatically update contributor lists, acknowledging all project participants without manual tracking.

  • Conventional commits enforced with commitlint: Enforce structured commit messages so release-please can automate changelog generation and version bumps.

  • Security policy: Establish clear vulnerability reporting procedures, promoting responsible disclosure and faster security fixes.

  • Code of conduct: Set community behavior expectations, fostering an inclusive and respectful project environment.

  • Contributing guidelines: Provide clear instructions for contributors, reducing friction for new participants.

  • Automated dependency security scanning with codeql: Detect vulnerable dependencies automatically, protecting your users from known security issues.

  • CLA (Contributor License Agreement) check via CLA Assistant: Ensure all contributors have signed appropriate licensing agreements, protecting the project legally.

IDE Integration

  • VS Code integration: Provide optimized settings and configurations for Visual Studio Code, enhancing developer productivity.

  • PyRight configuration: Enable accurate, real-time type checking in the editor, catching errors before running tests.

  • Editor extensions recommendations: Suggest optimal VS Code extensions automatically, standardizing the development environment.

AI Integration

  • AI assistance with common agents Cursor, Windsurf, Claude Code, Codex: Support popular AI coding assistants enabling AI-powered development.

  • Cursor Rules configuration: Optimize Cursor AI assistant for your specific project structure, improving suggestion relevance.

  • Windsurf Rules configuration: Configure Windsurf IDE to understand your project architecture, enhancing code generation quality.

Start your next Python project with confidence, knowing you're building on a foundation of best practices and modern development tools.

Full documentation on ReadTheDocs including how to run

Metadata

Release files for py_launch_blueprint 4.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for py_launch_blueprint 4.0.1
File Size Uploaded
py_launch_blueprint-4.0.1.tar.gz 66.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for py_launch_blueprint 4.0.1
File Interpreter ABI Platform
py_launch_blueprint-4.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 165.5 kB

Release files / py_launch_blueprint-4.0.1.tar.gz

Download URL py_launch_blueprint-4.0.1.tar.gz
Size 66.5 kB
Tags Source
SHA-256 checksum
How to use checksums
59d5f8cdb3b8a80a1339e579b357f7fbb74d777afc0ff920a741f91f10828ec8
BLAKE2b-256 checksum
How to use checksums
87fde492eed38834c37198b95629bb730463121725ad97a280db719a9c0b6e79
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.14 {"installer":{"name":"uv","version":"0.12.14","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / py_launch_blueprint-4.0.1-py3-none-any.whl

Download URL py_launch_blueprint-4.0.1-py3-none-any.whl
Size 99.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d8e851f4ebbd69eb854d59c51781cf2df642827c6f58730f6fd1b285f44b507a
BLAKE2b-256 checksum
How to use checksums
bb883c243f49dac65d0b56b5e8d4df58fe9224d7dbaa4f4cf7ccb8ff98f2f9a0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.14 {"installer":{"name":"uv","version":"0.12.14","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release history Release notifications | RSS feed

This release

4.0.1 This release

2 release files

4.0.0

2 release files

3.0.0

2 release files

2.4.2

2 release files

2.4.1

2 release files

2.4.0

2 release files

2.3.0

2 release files

2.2.0

2 release files

2.1.1

2 release files

2.1.0

2 release files

2.0.1

2 release files

2.0.0

2 release files

1.1.7

2 release files

1.1.6

2 release files

1.1.5

2 release files

1.1.4

2 release files

1.1.3

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page