You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "potiuk (via GitHub)" <gi...@apache.org> on 2026/03/15 10:06:45 UTC
[PR] Warn instead of failing on missing 3rd-party doc inventories [airflow]
potiuk opened a new pull request, #63630:
URL: https://github.com/apache/airflow/pull/63630
Third-party Sphinx intersphinx inventories (e.g., Pandas) are sometimes
temporarily unavailable. Previously, any download failure terminated the
entire doc build with `SystemExit(1)`. This is too aggressive — these
inventories are for cross-references to external docs and their temporary
unavailability should not block the build.
**Changes:**
- Missing 3rd-party inventories now produce warnings instead of failing
- If a cached version exists, it is used with a warning
- A `.missing_third_party_inventories` marker file is written for CI detection
- Canary builds send Slack warnings to `internal-airflow-ci-cd` when inventories are missing
- Publishing workflow fails by default on missing inventories but has an opt-out flag
**New flags:**
- `--fail-on-missing-third-party-inventories` — opt-in to fail on missing 3rd-party inventories
- `--clean-inventory-cache` — separate flag to clean inventory cache (`--clean-build` no longer deletes it)
- `--ignore-missing-inventories` — workflow dispatch input for publish-docs
**Files changed:**
- `fetch_inventories.py` — warn-and-continue logic, marker file
- `build_docs.py` — new CLI flags
- `doc_build_params.py` — new fields and arg passing
- `developer_commands.py` — new CLI flags, updated clean-build behavior
- `workflow_commands.py` — `--ignore-missing-inventories` option
- `ci-image-checks.yml` — fixed stash key/condition, Slack notification
- `ci-amd-arm.yml` — pass SLACK_BOT_TOKEN secret
- `publish-docs-to-s3.yml` — inventory cache stash, fail flag, workflow input
---
##### Was generative AI tooling used to co-author this PR?
- [X] Yes — Claude Code (Claude Opus 4.6)
Generated-by: Claude Code (Claude Opus 4.6) following [the guidelines](https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#gen-ai-assisted-contributions)
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Warn instead of failing on missing 3rd-party doc inventories [airflow]
Posted by "potiuk (via GitHub)" <gi...@apache.org>.
potiuk commented on code in PR #63630:
URL: https://github.com/apache/airflow/pull/63630#discussion_r2936563422
##########
contributing-docs/11_documentation_building.rst:
##########
@@ -239,7 +239,30 @@ For example:
breeze build-docs --doc-only --clean fab
-Will build ``fab`` provider documentation and clean inventories and other build artifacts before.
+Will build ``fab`` provider documentation and clean build artifacts before.
+
+Inventory cache handling
+........................
+
+When building documentation, Sphinx downloads intersphinx inventories from external sources (both Airflow
+packages hosted on S3 and third-party packages like Pandas, SQLAlchemy, etc.). These inventories enable
+cross-references between documentation sets.
+
+By default, missing third-party inventories produce warnings but do **not** fail the build. This is
+because third-party inventory servers can be temporarily unavailable and should not block documentation
+builds. If a cached version of the inventory exists, it will be used instead.
+
+The following flags control inventory behavior:
+
+- ``--clean-inventory-cache`` — deletes the inventory cache before fetching. Use this when you want
+ to force a completely fresh download of all inventories.
+- ``--clean-build`` — cleans build artifacts (``_build``, ``_doctrees``, ``apis``) but does **not**
+ delete the inventory cache. This allows rebuilding docs from scratch while preserving cached
+ inventories.
+- ``--refresh-airflow-inventories`` — forces a refresh of only Airflow package inventories, without
+ cleaning build artifacts or external inventories.
+- ``--fail-on-missing-third-party-inventories`` — fails the build if any third-party inventory cannot
+ be downloaded (useful for publishing workflows where complete cross-references are important).
Review Comment:
I don't think so:
* we have canary build posting us warnings where inventories are missing (so we will be aware of it )
* ignore missing inventories is set to false by default in publishing workflow (i.e. the one we are using to publish docs to airflow.apache.org
* We can als override it when publishing if it holds us back and we want to publish docs quickly anyway (`breeze workflow-run publish-docs --ignore-missing-inventories`.
I do not think we should do anything different with tag? But maybe I am missing something ? Not sure exactly if I understand what you propose :)
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Warn instead of failing on missing 3rd-party doc inventories [airflow]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #63630:
URL: https://github.com/apache/airflow/pull/63630#issuecomment-4063001166
### Backport failed to create: v3-1-test. View the failure log <a href='https://github.com/apache/airflow/actions/runs/23111414468'> Run details </a>
Note: As of [Merging PRs targeted for Airflow 3.X](https://github.com/apache/airflow/blob/main/dev/README_AIRFLOW3_DEV.md#merging-prs-targeted-for-airflow-3x)
the committer who merges the PR is responsible for backporting the PRs that are bug fixes (generally speaking) to the maintenance branches.
In matter of doubt please ask in [#release-management](https://apache-airflow.slack.com/archives/C03G9H97MM2) Slack channel.
<table>
<tr>
<th>Status</th>
<th>Branch</th>
<th>Result</th>
</tr>
<tr>
<td>❌</td>
<td>v3-1-test</td>
<td><a href="https://github.com/apache/airflow/commit/afda438816b8e8cd43ef105630c8f33da8ec98b5"><img src='https://img.shields.io/badge/Commit-afda438-red' alt='Commit Link'></a></td>
</tr>
</table>
You can attempt to backport this manually by running:
```bash
cherry_picker afda438 v3-1-test
```
This should apply the commit to the v3-1-test branch and leave the commit in conflict state marking
the files that need manual conflict resolution.
After you have resolved the conflicts, you can continue the backport process by running:
```bash
cherry_picker --continue
```
If you don't have cherry-picker installed, see the [installation guide](https://github.com/apache/airflow/blob/main/dev/README_AIRFLOW3_DEV.md#how-to-backport-pr-with-cherry-picker-cli).
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Warn instead of failing on missing 3rd-party doc inventories [airflow]
Posted by "potiuk (via GitHub)" <gi...@apache.org>.
potiuk merged PR #63630:
URL: https://github.com/apache/airflow/pull/63630
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Warn instead of failing on missing 3rd-party doc inventories [airflow]
Posted by "Dev-iL (via GitHub)" <gi...@apache.org>.
Dev-iL commented on code in PR #63630:
URL: https://github.com/apache/airflow/pull/63630#discussion_r2936573744
##########
contributing-docs/11_documentation_building.rst:
##########
@@ -239,7 +239,30 @@ For example:
breeze build-docs --doc-only --clean fab
-Will build ``fab`` provider documentation and clean inventories and other build artifacts before.
+Will build ``fab`` provider documentation and clean build artifacts before.
+
+Inventory cache handling
+........................
+
+When building documentation, Sphinx downloads intersphinx inventories from external sources (both Airflow
+packages hosted on S3 and third-party packages like Pandas, SQLAlchemy, etc.). These inventories enable
+cross-references between documentation sets.
+
+By default, missing third-party inventories produce warnings but do **not** fail the build. This is
+because third-party inventory servers can be temporarily unavailable and should not block documentation
+builds. If a cached version of the inventory exists, it will be used instead.
+
+The following flags control inventory behavior:
+
+- ``--clean-inventory-cache`` — deletes the inventory cache before fetching. Use this when you want
+ to force a completely fresh download of all inventories.
+- ``--clean-build`` — cleans build artifacts (``_build``, ``_doctrees``, ``apis``) but does **not**
+ delete the inventory cache. This allows rebuilding docs from scratch while preserving cached
+ inventories.
+- ``--refresh-airflow-inventories`` — forces a refresh of only Airflow package inventories, without
+ cleaning build artifacts or external inventories.
+- ``--fail-on-missing-third-party-inventories`` — fails the build if any third-party inventory cannot
+ be downloaded (useful for publishing workflows where complete cross-references are important).
Review Comment:
My thought was roughly this: assuming 1) inventories can't be fetched from the regular source; 2) there's an alternate source for them (e.g. internet archive) but it's rate limited or there's another reason to not use it frequently; and 3) we need to refresh the cache "right now" - allow fetching inventories from fallback path via tag.
Maybe this is sufficiently rare that we don't even care. Feel free to ignore...
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Warn instead of failing on missing 3rd-party doc inventories [airflow]
Posted by "Dev-iL (via GitHub)" <gi...@apache.org>.
Dev-iL commented on code in PR #63630:
URL: https://github.com/apache/airflow/pull/63630#discussion_r2936573744
##########
contributing-docs/11_documentation_building.rst:
##########
@@ -239,7 +239,30 @@ For example:
breeze build-docs --doc-only --clean fab
-Will build ``fab`` provider documentation and clean inventories and other build artifacts before.
+Will build ``fab`` provider documentation and clean build artifacts before.
+
+Inventory cache handling
+........................
+
+When building documentation, Sphinx downloads intersphinx inventories from external sources (both Airflow
+packages hosted on S3 and third-party packages like Pandas, SQLAlchemy, etc.). These inventories enable
+cross-references between documentation sets.
+
+By default, missing third-party inventories produce warnings but do **not** fail the build. This is
+because third-party inventory servers can be temporarily unavailable and should not block documentation
+builds. If a cached version of the inventory exists, it will be used instead.
+
+The following flags control inventory behavior:
+
+- ``--clean-inventory-cache`` — deletes the inventory cache before fetching. Use this when you want
+ to force a completely fresh download of all inventories.
+- ``--clean-build`` — cleans build artifacts (``_build``, ``_doctrees``, ``apis``) but does **not**
+ delete the inventory cache. This allows rebuilding docs from scratch while preserving cached
+ inventories.
+- ``--refresh-airflow-inventories`` — forces a refresh of only Airflow package inventories, without
+ cleaning build artifacts or external inventories.
+- ``--fail-on-missing-third-party-inventories`` — fails the build if any third-party inventory cannot
+ be downloaded (useful for publishing workflows where complete cross-references are important).
Review Comment:
My thought was roughly this: assuming 1) inventories can't be fetched from the regular source; 2) there's an alternate source for them but it's rate limited or some other reason to not use it always; and 3) we need to refresh the cache "right now" - allow fetching inventories from fallback path via tag.
Maybe this is sufficiently rare that we don't even care. Feel free to ignore...
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Warn instead of failing on missing 3rd-party doc inventories [airflow]
Posted by "potiuk (via GitHub)" <gi...@apache.org>.
potiuk commented on code in PR #63630:
URL: https://github.com/apache/airflow/pull/63630#discussion_r2936607258
##########
contributing-docs/11_documentation_building.rst:
##########
@@ -239,7 +239,30 @@ For example:
breeze build-docs --doc-only --clean fab
-Will build ``fab`` provider documentation and clean inventories and other build artifacts before.
+Will build ``fab`` provider documentation and clean build artifacts before.
+
+Inventory cache handling
+........................
+
+When building documentation, Sphinx downloads intersphinx inventories from external sources (both Airflow
+packages hosted on S3 and third-party packages like Pandas, SQLAlchemy, etc.). These inventories enable
+cross-references between documentation sets.
+
+By default, missing third-party inventories produce warnings but do **not** fail the build. This is
+because third-party inventory servers can be temporarily unavailable and should not block documentation
+builds. If a cached version of the inventory exists, it will be used instead.
+
+The following flags control inventory behavior:
+
+- ``--clean-inventory-cache`` — deletes the inventory cache before fetching. Use this when you want
+ to force a completely fresh download of all inventories.
+- ``--clean-build`` — cleans build artifacts (``_build``, ``_doctrees``, ``apis``) but does **not**
+ delete the inventory cache. This allows rebuilding docs from scratch while preserving cached
+ inventories.
+- ``--refresh-airflow-inventories`` — forces a refresh of only Airflow package inventories, without
+ cleaning build artifacts or external inventories.
+- ``--fail-on-missing-third-party-inventories`` — fails the build if any third-party inventory cannot
+ be downloaded (useful for publishing workflows where complete cross-references are important).
Review Comment:
Yeah. It's rare enough - and internet archive might be even more unreliable to be honest.
Also - since we are not cleaning the inventories by default even with `--clean-build` (we just attempt to fetch the new ones but will not delete ones we cannot fetch) - in many cases it will **just** work because we will already have the inventory in the cache, so things will **generally** work fine - at most with some outdated inventory.
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Warn instead of failing on missing 3rd-party doc inventories [airflow]
Posted by "Dev-iL (via GitHub)" <gi...@apache.org>.
Dev-iL commented on code in PR #63630:
URL: https://github.com/apache/airflow/pull/63630#discussion_r2936552124
##########
contributing-docs/11_documentation_building.rst:
##########
@@ -239,7 +239,30 @@ For example:
breeze build-docs --doc-only --clean fab
-Will build ``fab`` provider documentation and clean inventories and other build artifacts before.
+Will build ``fab`` provider documentation and clean build artifacts before.
+
+Inventory cache handling
+........................
+
+When building documentation, Sphinx downloads intersphinx inventories from external sources (both Airflow
+packages hosted on S3 and third-party packages like Pandas, SQLAlchemy, etc.). These inventories enable
+cross-references between documentation sets.
+
+By default, missing third-party inventories produce warnings but do **not** fail the build. This is
+because third-party inventory servers can be temporarily unavailable and should not block documentation
+builds. If a cached version of the inventory exists, it will be used instead.
+
+The following flags control inventory behavior:
+
+- ``--clean-inventory-cache`` — deletes the inventory cache before fetching. Use this when you want
+ to force a completely fresh download of all inventories.
+- ``--clean-build`` — cleans build artifacts (``_build``, ``_doctrees``, ``apis``) but does **not**
+ delete the inventory cache. This allows rebuilding docs from scratch while preserving cached
+ inventories.
+- ``--refresh-airflow-inventories`` — forces a refresh of only Airflow package inventories, without
+ cleaning build artifacts or external inventories.
+- ``--fail-on-missing-third-party-inventories`` — fails the build if any third-party inventory cannot
+ be downloaded (useful for publishing workflows where complete cross-references are important).
Review Comment:
Do we want to tie any of these to a github tag?
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Warn instead of failing on missing 3rd-party doc inventories [airflow]
Posted by "potiuk (via GitHub)" <gi...@apache.org>.
potiuk commented on PR #63630:
URL: https://github.com/apache/airflow/pull/63630#issuecomment-4062841509
> Awesome! This was making CI flaky for two days adn possible more in the future
🤞 ... Still some small issues with CI but hopefully the last one will fix it :)
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org