Modernize the python template#228
Merged
Merged
Conversation
- 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.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
An overhaul of the template to use modern tooling and better support agent driven work.