Tags: Preocts/python-src-template
Tags
Pass python version to uv (#216) This change reverts the use of `python=False` in all nox sessions. Sessions for tests, linting, and formatting will use nox virtual environments. In these sessions the location of the virtual environment will be passed to `uv run` and `uv sync`. This means uv will use the python version that nox is executed with. This change is needed because nox correctly masks all environment variables when starting a `session.run` or `session.run_install`. This is ideal to maintain repeatable behavior. This is not ideal when attempting to use `UV_PYTHON` to control which version is being run. Enforcing that uv use the python version that nox is executed with is the least surprising behavior. Even if this ignores the `.python-version` file in the repo.
Clean up gha python setup (#214) * Remove settings job Turns out the setup-python action already looks for and respects the `.python-version` pin. Easy mode. * Use correct python version * Remove python-setup * Remove only system flag * no-config parameter is not needed
Guard against uv.lock drift (#208) Add a pre-commit hook to ensure the lockfile has been updated with any dependency changes. Likewise, create a nox session to do the same. This combination will help ensure the uv.lock file is correct even when pushed before updating. pre-commit-ci can auto-fix this.