Skip to content

Modernize the python template#228

Merged
gpauloski merged 9 commits into
mainfrom
gpauloski/v2
Jul 19, 2026
Merged

Modernize the python template#228
gpauloski merged 9 commits into
mainfrom
gpauloski/v2

Conversation

@gpauloski

Copy link
Copy Markdown
Owner

An overhaul of the template to use modern tooling and better support agent driven work.

- Move dev tooling to PEP 735 dependency-groups; add prek and tox-uv
- Keep setuptools + setuptools_scm build backend
- Add keywords placeholder to project metadata
- Commit uv.lock for a reproducible dev environment
- Add .python-version and trim .gitignore to essentials
- Ruff select=ALL with commented ignores for formatter conflicts,
  redundant pydocstyle rules, and copyright headers
- Per-file-ignores relax test/example/docs helper rules
- Enforce LF line endings via the formatter
- mypy strict=true; exclude docs helper scripts
- Remove dead 'import sys' from package __init__
- Migrate to prek (drop-in pre-commit replacement) for docs/workflows
- Replace codespell with crate-ci/typos; move config to [tool.typos]
- Add complexipy cognitive-complexity hook; drop overlapping Ruff C901/PLR0912
- Add default hooks (check-case-conflict, check-toml, debug-statements)
- Run mypy via local uv env for strict, dependency-aware checks
- Add prek CI check and weekly prek-autoupdate cron workflow
- Fix typo caught by typos in releases doc
- tox.ini uses tox-uv-bare's uv-venv-lock-runner with dependency groups
- Replace pip-cache steps with astral-sh/setup-uv (built-in caching)
- Run tests/docs via 'uv run tox'; build with 'uv build'
- publish.yml uses PyPI Trusted Publishing (OIDC), dropping PYPI_TOKEN
- Add least-privilege permissions blocks; keep cache-cleanup workflow
- Rewrite README around uv/prek/tox and template bootstrapping
- Update contributing dev-setup docs to the uv/prek workflow
- Add repository-setup guide (repo defaults, Trusted Publishing, labels)
- Make CODE_OF_CONDUCT contact generic; PR template references prek
- Harden mypy exclude against local build artifacts (site/, build/, dist/)
- Ignore .complexipy_cache/
- Remove dead pytkdocs_tweaks setup_commands (ignored by griffe handler)
- Rename handler 'import' to 'inventories' for current mkdocstrings
- Fix wrong placeholder URL in custom mkdocstrings template
- Loosen docs deps to lower bounds (uv.lock pins exact versions)
- Refresh lockfile to latest compatible docs/dev tooling
- AGENTS.md: single source of truth (layout, tooling, commands, conventions)
- CLAUDE.md imports AGENTS.md to avoid duplication
- Add starter Claude Code skills: check, rename-template, release, add-docs-page
- tests.yml: set setup-uv python-version from the matrix (exports UV_PYTHON)
  so the tox driver venv and the env under test share one interpreter,
  instead of also provisioning the .python-version default (3.13)
- Enable cache-python across workflows to cache interpreter downloads
- Drop now-redundant explicit 'uv python install' steps
- Remove examples/ and its references (README, AGENTS.md, coverage omit,
  ruff per-file-ignores). Keeps docs/examples.md as usage documentation.
- Replace the inconsistent foobar/FooBar/Foobar/foobar-author placeholders
  with exactly two lowercase tokens: pypkg and pypkg-author. Author email
  now uses the reserved example.com domain.
- Document an activated-venv workflow (uv sync + source .venv/bin/activate)
  and invoke tools directly (prek run, pytest, tox) instead of via uv run.
  CI and the mypy git hook keep 'uv run' since no shell is activated there.
@gpauloski gpauloski closed this Jul 19, 2026
@gpauloski gpauloski reopened this Jul 19, 2026
@gpauloski
gpauloski merged commit 252172c into main Jul 19, 2026
13 of 14 checks passed
@gpauloski
gpauloski deleted the gpauloski/v2 branch July 19, 2026 23:23
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