From 028d2469f350d559490e623a232c71ef3f63d90e Mon Sep 17 00:00:00 2001 From: melbinjp Date: Mon, 17 Aug 2026 23:12:18 +0530 Subject: [PATCH] Scheduled CI: the 3.10 jobs could never pass, and it was our code not a dependency The Fresh Install matrix tests Python 3.10 and 3.14, and pyproject declares requires-python = ">=3.10". The Build Wheel step then ran: python -c "import tomllib; ..." tomllib entered the stdlib in 3.11. So all three 3.10 jobs (ubuntu, macos, windows) failed deterministically at that line, on every scheduled run since 2026-08-03, while 3.14 passed. The wheel itself was never the problem. The log says "Successfully built rigout-0.3.1-py3-none-any.whl" immediately before the traceback, and the traceback frame is File "", line 1 - the inline -c, not the build. That matters because the auto-filed issue (#28) says a scheduled failure with no code change is "almost certainly a newly published dependency" and points at resolved dependency versions. Here that hypothesis was wrong and it is the reason this sat for three weeks: anyone who followed it went looking through dependency bounds for a break that was six lines away in our own workflow. Fix is the standard fallback, with tomli installed only where it is needed. Both branches were executed before pushing - tomllib present and tomllib forced absent - and both return 0.3.1. Note, deliberately not changed: scheduled-ci.yml has a second tomllib use in Compare Caps Against Latest On PyPI. That job pins Python 3.12, so it is correct today and touching it would widen this diff. It would break the same way if that pin ever moved below 3.11. --- .github/workflows/scheduled-ci.yml | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/.github/workflows/scheduled-ci.yml b/.github/workflows/scheduled-ci.yml index 630331c..d2855ba 100644 --- a/.github/workflows/scheduled-ci.yml +++ b/.github/workflows/scheduled-ci.yml @@ -78,9 +78,18 @@ jobs: # A stale dist/ from an earlier build would be installed silently, so the # run would test a wheel that is not the one this commit produces. rm -rf dist - python -m pip install --upgrade pip build + # tomli is the pre-3.11 half of the tomllib fallback below. pyproject declares + # requires-python = ">=3.10" and this matrix tests 3.10, but tomllib only entered + # the stdlib in 3.11 - so the version check below could never run on the oldest + # Python the package claims to support. + python -m pip install --upgrade pip build 'tomli; python_version < "3.11"' python -m build --wheel - expected="$(python -c "import tomllib;print(tomllib.load(open('pyproject.toml','rb'))['project']['version'])")" + expected="$(python -c " + try: + import tomllib + except ModuleNotFoundError: # Python 3.10 + import tomli as tomllib + print(tomllib.load(open('pyproject.toml','rb'))['project']['version'])")" echo "EXPECTED_VERSION=$expected" >> "$GITHUB_ENV" count="$(ls dist/*.whl | wc -l)" if [ "$count" -ne 1 ]; then