legout/skills

modern-python

Configures Python projects with modern tooling (uv, ruff, ty).

Ver código fuente

Cómo usar

  1. Copia el comando y revisa el paquete antes de instalarlo en tu entorno de agente.
  2. Consulta las herramientas, credenciales y entornos necesarios en el documento original.
  3. Describe las entradas y el resultado deseado; contrasta la salida con las fuentes.
npx skills add https://github.com/legout/skills --skill modern-python

Antes de empezar

  • La instalación no incluye suscripción al modelo, cuota API ni permisos sobre tus archivos.
  • Las estrellas e instalaciones reflejan actividad, no una prueba independiente de calidad o seguridad.
Documento original del Skill

Contenido del repositorio de origen con títulos, ejemplos, código, tablas, enlaces e imágenes preservados.

Modern Python

Before changing a project, read its instructions and current configuration, preserve supported Python versions, and run installed CLI help. Do not replace a working toolchain unless the user requests migration and the replacement reaches validation parity.

Route

Defaults for new work

  • Manage dependencies with uv add, uv remove, and uv sync; run commands with uv run.
  • Use dependency groups for development tools.
  • Use Ruff for lint and format, ty for type checks, and pytest for tests unless project constraints require otherwise.
  • Prefer uv_build for ordinary new packages.
  • Never manually activate or manage a virtualenv.

Minimal project

bash
uv init myproject
cd myproject
uv add requests
uv add --group dev pytest ruff ty
uv run ruff check .
uv run ty check
uv run pytest

For repository documentation, follow its existing system. If it uses Zensical, validate with uv run zensical build; use uv run zensical serve only for interactive preview.

Verification

Run the project's existing checks plus Ruff, ty, and tests when configured. During migration, compare old and new validation results before deleting legacy configuration. Hand versioning or publication to make-release.

Source

Adapted under CC-BY-SA-4.0 from Trail of Bits' `modern-python` package, pinned to commit d3323cefbcf645678b8dc481de204b02ad3d02dc. See sources.json and THIRD_PARTY_NOTICES.md.

del mismo repositorio

Más Skills

Todos los Skills