Skip to content

Repo checker: from wheelgap 0.16.0, the gate workflow takes the Python from .python-version - #302

Merged
patrickballard merged 2 commits into
mainfrom
check/workflow-python-from-project
Dec 1, 2026
Merged

patrickballard merged 2 commits into
mainfrom
check/workflow-python-from-project

Conversation

@patrickballard

@patrickballard patrickballard commented Dec 1, 2026 •

Copy link
Copy Markdown
Contributor

wheelgap/wheelgap#870 (merged in wheelgap/wheelgap#903, to be released in 0.16.0) makes the compare-to gate without -p check each side on its own .python-version, so a pull request that only bumps the Python is caught. With -p in args, as the checker offers today, it isn't.

The offered workflow now leaves -p out, with a comment saying the Python comes from .python-version, only when all of these hold:

  • the page's wheelgap pin is 0.16.0 or later, so nothing changes until the pin moves;
  • the lockfile is at the root, since wheelgap reads .python-version beside it;
  • its pyproject.toml sets no [tool.wheelgap] python (config_python), which wheelgap reads first;
  • wheelgap's own reading of .python-version (python_version from the driver) is exactly the one Python selected.

The driver's reader matches wheelgap.cli.read_python_version, and a test compares the two on 13 sample files. The page's default Python is unchanged. Otherwise the workflow keeps -p, which the gate then needs, because 0.16.0 stops when neither side names a Python.

Tests: all 273 site tests, and tests/test_check_driver.py plus tests/test_check_parity.py with wheelgap 0.15.0 as CI runs them (273 passed).

patrickballard and others added 2 commits December 1, 2026 17:24
…n from .python-version

wheelgap#870 makes compare-to without -p check each side on its own .python-version, so a pull request
that only bumps it is caught. The offered workflow leaves -p out when the root .python-version picked the
Python, the lockfile is at the root and the selection is just that Python; otherwise it keeps -p.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ected Python

Review fixes: the driver now reports wheelgap's own reading of .python-version (python_version; a test
compares it with wheelgap.cli.read_python_version), since the page's default reading takes 3.13.0rc1,
cpython-3.13 or a first line wheelgap ignores, and drops the t of 3.14.0t. And check reports
config_python: [tool.wheelgap] python beside the lockfile is read before .python-version, so -p stays.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@patrickballard
patrickballard merged commit 68d0574 into main Dec 1, 2026
1 check passed
@patrickballard
patrickballard deleted the check/workflow-python-from-project branch December 1, 2026 17:35
This was referenced Dec 1, 2026
patrickballard added a commit that referenced this pull request Dec 2, 2026
The checker's workflow now leaves -p out when the project's .python-version
names the Python it checked (#302), so its gate catches a move to another Python.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
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