summaryrefslogtreecommitdiff
path: root/docs/_utils.py
AgeCommit message (Collapse)Author
2026-10-29Ensured docs checks cover same files as docs builds.Mike Edmunds
Updated docs `make black` and `make lint` checks to use Sphinx's own source file discovery to get the list of docs source files. This makes docs/conf.py the single source of truth for which files are/aren't docs sources. The exclusions were previously duplicated by hand in Makefile, make.bat, and lint.py, where they could drift from conf.py. Created a Python blacken-sources.py wrapper around blacken-docs, similar to the existing lint.py for sphinx-lint. This replaces shell and batch file commands that tried (only partially successfully) to replicate Sphinx's source discovery. Removed `--jobs 0` from the sphinx-lint arguments to allow parallel linting, since sphinx-lint treats `--jobs 0` as serial instead of defaulting to `auto`. Also added Sphinx to the tox environments running the docs checks, since neither `blacken-docs` nor `sphinx-lint` depends on Sphinx. Thanks to Natalia Bidart for review and improvements.