shahar1 opened a new pull request, #74168: URL: https://github.com/apache/airflow/pull/74168
related: #74151 related: #74167 <details><summary>AI Summary</summary> The docs build runs on the default Python, and `uv.lock` resolves Sphinx 8.1.3 on Python 3.10 but Sphinx 9.0.4 on 3.11 (9.1.0 on 3.12+). Moving the default to 3.11 (#74151) therefore moves the docs build to Sphinx 9, and the docs and spellcheck jobs fail. Part of that failure is an upstream regression, sphinx-doc/sphinx#14223: Sphinx 9 added a fallback from a `py:class` lookup to a fuzzy `py:data`/`py:attr` search when resolving annotation cross-references. A builtin such as `type` or `object` in an annotation then matches every documented attribute with that name: ``` WARNING: more than one target found for cross-reference 'type': airflow.providers.openlineage.plugins.facets.UnknownOperatorInstance.type, airflow.providers.openlineage.utils.utils.AssetInfo.type WARNING: more than one target found for cross-reference 'object': airflow.providers.google.cloud.sensors.gcs.GCSObjectExistenceSensor.object, airflow.providers.google.cloud.sensors.gcs.GCSObjectUpdateSensor.object ``` The new `python_builtin_xrefs` extension overrides the Python domain's `resolve_xref` so that a builtin name with no exact match is left unresolved instead of going through that fallback. Intersphinx then links it to the Python docs, which is what Sphinx 8 did. Non-builtin names are untouched. A plain `suppress_warnings = ["ref.python"]` would hide the warning but leave `type`/`object` linking to an unrelated attribute. The extension is registered in `BASIC_SPHINX_EXTENSIONS` (used by the core, provider, chart, ctl and docker-stack docs). Removal is tracked in #74167. The remaining Sphinx 9 warnings are genuine docstring mistakes and are fixed separately in the companion PR. Checks run: the new test passes on Sphinx 9.0.4 (Python 3.11) and 8.1.3 (Python 3.10) and fails on 9.0.4 without the extension; `mypy-devel-common` passes; with both PRs applied, `--docs-only` for amazon, google, openlineage and task-sdk passes on Python 3.11 / Sphinx 9.0.4, and google spellcheck passes. </details> --- ##### Was generative AI tooling used to co-author this PR? - [X] Yes — Claude Code (Opus 5.5) Generated-by: Claude Code (Opus 5.5) following [the guidelines](https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#gen-ai-assisted-contributions) 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01SkLWWaTT1cnFqTT1jhFGxe -- 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]
