augur
augur copied to clipboard
Check docs build in CI
Context
Currently, the docs build shows warnings that have slipped through due to a lack of CI (prompting manual fixes in #1046). This was also the case with ncov, which https://github.com/nextstrain/ncov/pull/941 addressed. Usage of docs-ci should be expanded to Augur docs as well as other docs projects.
However, docs-ci is not directly usable by the Augur docs project. This is because it requires a Conda environment file to set up the environment, and the Augur docs project does not have one. Instead, the environment is set up using:
https://github.com/nextstrain/augur/blob/862bbb6bf2806cfa4f5ec3a1f5a24a8ca83c14b6/docs/contribute/DEV_DOCS.md?plain=1#L291
Possible solutions
- Create a Conda environment file in the Augur docs project. This must include all of the setup.py base packages + extra
dev
packages, and would be an additional list of dependencies to maintain. - Update docs-ci to allow either setup using Conda or pip. However, it's unclear how to parameterize this. Maybe have an input
pip-install-target
andrun: pip install -e '{{ inputs.pip-install-target }}'
? - Update docs-ci to be an action instead of workflow, so it's up to the calling workflow to set up the environment. But then the action would just be running
make
with some predefinedSPHINXOPTS
.
I'd vote for (2), which was a previous suggestion of mine as well.
Docs CI should also check that all Python modules under augur/
have a corresponding .rst
file and properly included in at least the Developer API docs (e.g. to ensure discrepancies such as ef44043a54a0b1dd0f0190507b0b2118614b6838 are noticed by CI and not manually).