docs: build the documentation as a check; Read the Docs hosts it - #29
Merged
Merged
Conversation
docs.yml built the site and pushed it to gh-pages with peaceiris/actions-gh-pages and cname: docs.avitai.bio. Every push to main deployed to a site that does not exist: the Pages settings API returns 404 for the repository, https://avitai.github.io/DiffBio returns 404, and docs.avitai.bio has no DNS records. Read the Docs builds and serves the documentation from .readthedocs.yaml, and https://diffbio.readthedocs.io returns 200. docs.yml now runs a strict mkdocs build on each pull request and each push to main that touches the docs, mkdocs.yml, the package source or the workflow, with a contents: read token and no deploy step. The concurrency group keeps cancel-in-progress: true, which tests/test_ci_concurrency.py requires of every workflow a push triggers. A contract test holds it there: no workflow uses a GitHub Pages deploy action or requests pages: write, docs.yml holds a read-only token, and it builds strictly on both events.
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
docs.ymlbecomes a build-only check: strictmkdocs buildon pull requests and pushes to main (same paths filter),contents: read, no deploy step.pages: write;docs.ymlholds a read-only token and builds strictly on both events.Why
The workflow deployed to
gh-pageswithcname: docs.avitai.bioon every push to main, but GitHub Pages is not enabled for the repository (Pages API 404),https://avitai.github.io/DiffBioreturns 404 anddocs.avitai.biohas no DNS records. Read the Docs builds and hosts the documentation from.readthedocs.yamland is live.The
gh-pagesbranch is left in place; it is removed separately after merge.Verification
mkdocs build --strict --cleanfrom a locked--extra docsenvironment: exit 0.pre-commit run --all-files: exit 0.