kaxil commented on code in PR #73477:
URL: https://github.com/apache/airflow/pull/73477#discussion_r4069686823
##########
.github/workflows/ci-image-checks.yml:
##########
@@ -204,6 +204,8 @@ jobs:
python: "${{ inputs.default-python-version }}"
use-uv: ${{ inputs.use-uv }}
make-mnt-writeable-and-cleanup: true
+ # The docs build only needs the CI image; the runner has ~90 GB free
without the cleanup.
+ free-up-disk-space: false
Review Comment:
Fair. I checked the 16 docs jobs on main over the last two days and all of
them start with 93 GB free, but that is not a guarantee, so I changed it to a
threshold: the docs job now passes `min-free-space-gb: 40` and the prepare
action runs the cleanup unless `/` already has at least that much free. The
docs job needs roughly 25 GB (image tar, loaded image, built docs). Other jobs
are unchanged (no threshold, cleanup always runs). 35c7240783.
##########
devel-common/src/docs/build_docs.py:
##########
@@ -693,52 +729,19 @@ def build_docs(
all_spelling_errors.update(package_spelling_errors)
if not one_pass_only:
- # Build documentation for some packages again if it can help them.
- package_build_errors = retry_building_docs_if_needed(
- all_build_errors=all_build_errors,
- all_spelling_errors=all_spelling_errors,
- autobuild=autobuild,
- docs_only=docs_only,
- jobs=jobs,
- verbose=verbose,
- package_build_errors=package_build_errors,
- originally_built_packages=packages_to_build,
- # If spellchecking fails, we need to rebuild all packages first in
case some references
- # are broken between packages
- rebuild_all_packages=spellcheck_only,
Review Comment:
The reason the old code had to rebuild everything with html was that
spelling builds produced no inventory. That is the part this PR changes:
`airflow_intersphinx` now writes `objects.inv` at the end of a spelling build
too, and prefers it over the downloaded one for packages built earlier in the
run. So the B -> A case resolves the same way it does in a docs build: B fails
the first pass on the missing label, the retry rebuilds only B, and B picks up
A's fresh inventory.
I reproduced exactly that locally with `--spellcheck-only ftp sftp`: a new
`.. _ftp-brand-new-label:` in the ftp docs, referenced with `:ref:` from the
sftp docs (sftp is heavier, so it is scheduled first):
```
apache-airflow-providers-ftp : Finished spell-checking successfully
apache-airflow-providers-sftp : Finished spell-checking with errors
providers/sftp/docs/index.rst:157: WARNING: undefined label:
'apache-airflow-providers-ftp:ftp-brand-new-label'
Some packages failed to build due to dependencies. We need another pass.
Packages to rebuild: ['apache-airflow-providers-sftp']
apache-airflow-providers-sftp : Finished spell-checking successfully
No packages to retry. No more passes are needed.
Documentation build is successful
```
The A -> B -> C chain still gets the two retry passes (three passes total);
they are no-ops when nothing failed. The retry predicate is the one that was
already there (retry only when an error is one of the "missing thing" kinds).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]