Repository navigation
DM-56905: Fix Periodic CI for Sphinx dev dropping Python 3.12 - #553
Merged
Merged
Conversation
Run make update-deps: refresh uv.lock and bump the ruff and prettier prek hooks.
Ruff 0.17 newly reports ISC004 (implicit string concatenation in a collection must be parenthesized) and ICN001 for datetime (import as dt) under select = ALL, and its formatter no longer wraps an import to make room for a trailing pragma comment.
Updating an author table added an empty affiliations array of tables even for an author with no affiliations. tomlkit 0.15.1 and earlier omitted an empty array of tables on output, but 0.15.2 serializes it as affiliations = [], so sync-authors rewrote otherwise healthy technote.toml files. Only create the array when there is an affiliation to add.
Sphinx's main branch (9.3.0 development) now requires Python 3.13, so the Sphinx dev override can't be installed on Python 3.12 and that cell of the Periodic CI matrix failed at dependency resolution every week. Skip the dev sessions on Pythons older than Sphinx's floor and exclude the cell from the Periodic CI matrix. Also turn off fail-fast for the Periodic CI test matrix so that one broken cell no longer cancels, and hides the results of, the others.
The test, typing, and demo sessions install a Sphinx version over the locked environment but left the locked sphinx-autodoc-typehints in place. That release is resolved for Sphinx 9, and since 3.14 it imports sphinx.ext.autodoc._dynamic, which Sphinx 8 doesn't have, so every guide build failed in the Sphinx 8 sessions once the lockfile moved past 3.13. Install the extension in the same uv pip install as Sphinx so the resolver picks a release that supports that Sphinx.
Documentation preview
Build |
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.
Summary
The weekly Periodic CI run has failed since 2026-10-26 (runs 40374010460, 41526175906, 42705867116) in the
test (3.12, dev)cell, at theRun noxstep:Root cause: Sphinx's main branch dropped Python 3.12 on 2026-10-20 (sphinx-doc/sphinx#14762; main is now 9.3.0 development with
requires-python = ">=3.13"). Thedevsessions install Sphinx from git, so that override can no longer be installed on Python 3.12. Because the matrix used the defaultfail-fast, that one cell also cancelled the other 11 cells every week.Changes
noxfile.py), and exclude the3.12/devcell from the Periodic CI matrix (.github/workflows/ci-cron.yaml). Sphinx 8 and 9 are still tested on Python 3.12. The floor is a single_SPHINX_DEV_MIN_PYTHONconstant in the noxfile.fail-fast: falseon the Periodic CI test matrix so one broken cell no longer hides the rest.make update-deps(uv.lock, ruff and prettier prek hooks). That update surfaced three more problems, fixed here:affiliations = [](0.15.1 and earlier omitted it). Documenteer added an emptyaffiliationsarray to every author table it touched, sotechnote sync-authorsstopped being a byte-for-byte no-op on a healthy file (tests/services/technoteauthor_test.py::test_sync_authors_leaves_a_healthy_file_byte_identical).src/documenteer/storage/technotetoml.pynow only creates the array when there is an affiliation to add. This is a user-facing fix, since tomlkit is unpinned for PyPI installs.sphinx.ext.autodoc._dynamic, which Sphinx 8 doesn't have. The nox sessions overrode Sphinx but kept the locked sphinx-autodoc-typehints (3.17.5, resolved for Sphinx 9), so 94 tests failed or errored in the Sphinx 8 sessions. The override now installs sphinx-autodoc-typehints in the sameuv pip installas Sphinx, so the resolver picks a release that supports that Sphinx (3.5.2 for Sphinx 8; the locked release is kept for Sphinx 9 and dev).datetimeasdt) and formats imports with trailing pragma comments differently. The code is fixed to comply; no rules were ignored.docs/dev/development.rst.Validation
Run locally (macOS) against the updated lockfile with
uv run --only-group=nox nox -s ...:test,typing, anddemofor3.12(sphinx='dev'): skipped with an explanatory message (previously failed at dependency resolution, reproduced locally).test,typing, anddemofor Sphinxdevon Python 3.13, 3.14, and 3.15: pass.test,typing, anddemofor3.13(sphinx='8'),3.13(sphinx='9'), and3.12(sphinx='9');test-3.12(sphinx='8'),typing-3.12(sphinx='8'), andtest-3.15(sphinx='8'): pass.lint,docs, andpackaging: pass.The Periodic CI workflow itself only runs on a schedule or by manual dispatch, so the
devcells aren't exercised by this pull request's checks. It can be run against this branch withgh workflow run ci-cron.yaml --ref tickets/DM-56905.