This is an automated email from the ASF dual-hosted git repository.

potiuk pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git


The following commit(s) were added to refs/heads/main by this push:
     new 23bcbe6c99a Regenerate provider requirement tables in breeze ci 
upgrade (#73802)
23bcbe6c99a is described below

commit 23bcbe6c99a3cf7dc5de9ebe4a45ad5a50513c44
Author: Jarek Potiuk <[email protected]>
AuthorDate: Mon Sep 28 11:39:04 2026 +0200

    Regenerate provider requirement tables in breeze ci upgrade (#73802)
    
    Raising dependency floors changes provider pyproject.toml files, but the
    requirement tables rendered from them into README.rst and docs/index.rst
    are only refreshed by prek hooks, and the upgrade commit is made without
    prek git hooks installed. Every upgrade PR that raised a provider floor
    therefore failed static checks until the tables were regenerated by hand.
    
    Generated-by: Claude Opus 5
---
 dev/breeze/doc/08_ci_tasks.rst                        |  4 +++-
 dev/breeze/src/airflow_breeze/commands/ci_commands.py |  9 +++++++++
 dev/breeze/tests/test_ci_upgrade.py                   | 16 ++++++++++++++--
 3 files changed, 26 insertions(+), 3 deletions(-)

diff --git a/dev/breeze/doc/08_ci_tasks.rst b/dev/breeze/doc/08_ci_tasks.rst
index 9d3e78aba9f..e1e29ef7528 100644
--- a/dev/breeze/doc/08_ci_tasks.rst
+++ b/dev/breeze/doc/08_ci_tasks.rst
@@ -47,7 +47,9 @@ root ``pyproject.toml``: a floor is raised to the newest 
release that is at leas
 old, members of a group share one floor, and packages that are capped anywhere 
or listed under
 ``exclude`` are never touched. Bumps that make ``uv lock`` fail - with the 
highest or the lowest-direct
 resolution - are rolled back and listed in the PR description together with 
everything that was
-raised or skipped. Use ``--no-upgrade-dependency-floors`` to skip the step. 
The design is recorded in
+raised or skipped. The provider ``README.rst`` and ``docs/index.rst`` 
requirement tables are then
+regenerated from the changed ``pyproject.toml`` files. Use 
``--no-upgrade-dependency-floors`` to skip
+both steps. The design is recorded in
 `ADR 0018 <adr/0018-raise-dependency-floors-automatically.md>`_.
 
 These are all available flags of ``upgrade`` command:
diff --git a/dev/breeze/src/airflow_breeze/commands/ci_commands.py 
b/dev/breeze/src/airflow_breeze/commands/ci_commands.py
index 380866140fd..a6a4bde2749 100644
--- a/dev/breeze/src/airflow_breeze/commands/ci_commands.py
+++ b/dev/breeze/src/airflow_breeze/commands/ci_commands.py
@@ -610,6 +610,14 @@ UPGRADE_COMMANDS: list[tuple[str, str]] = [
         "upgrade-dependency-floors",
         "prek --all-files --show-diff-on-failure --color always --verbose 
--stage manual upgrade-dependency-floors",
     ),
+    (
+        # Raised floors change provider pyproject.toml files, but the 
requirement tables rendered
+        # from them into README.rst and docs/index.rst are only refreshed by 
these hooks, and the
+        # upgrade commit is not made with prek hooks installed, so CI's 
--all-files run goes red.
+        "regenerate-provider-requirement-tables",
+        "prek --all-files --show-diff-on-failure --color always --verbose "
+        "update-providers-build-files sync-provider-readme",
+    ),
     (
         "update-uv-lock",
         "uv lock --upgrade",
@@ -648,6 +656,7 @@ def get_step_enabled(
         "update-chart-dependencies": update_chart_dependencies,
         "upgrade-important-versions": upgrade_important_versions,
         "upgrade-dependency-floors": upgrade_dependency_floors,
+        "regenerate-provider-requirement-tables": upgrade_dependency_floors,
         "update-uv-lock": update_uv_lock,
         "regenerate-datamodels": update_uv_lock,
     }
diff --git a/dev/breeze/tests/test_ci_upgrade.py 
b/dev/breeze/tests/test_ci_upgrade.py
index f44b5218b9b..1bdf48a7e7d 100644
--- a/dev/breeze/tests/test_ci_upgrade.py
+++ b/dev/breeze/tests/test_ci_upgrade.py
@@ -43,6 +43,15 @@ def test_floor_step_runs_the_manual_hook():
     assert command.endswith("--stage manual upgrade-dependency-floors")
 
 
+def test_provider_requirement_tables_are_regenerated_after_the_floor_step():
+    assert STEP_NAMES.index("upgrade-dependency-floors") < STEP_NAMES.index(
+        "regenerate-provider-requirement-tables"
+    )
+    command = dict(UPGRADE_COMMANDS)["regenerate-provider-requirement-tables"]
+    assert command.startswith("prek --all-files ")
+    assert command.endswith(" update-providers-build-files 
sync-provider-readme")
+
+
 @pytest.mark.parametrize(
     ("report", "expected_suffix"),
     [
@@ -89,9 +98,12 @@ def test_step_enabled_covers_every_step():
     assert set(get_step_enabled(**ALL_STEPS_ON)) == set(STEP_NAMES)
 
 
-def test_no_upgrade_dependency_floors_disables_only_that_step():
+def test_no_upgrade_dependency_floors_disables_only_the_floor_steps():
     enabled = get_step_enabled(**{**ALL_STEPS_ON, "upgrade_dependency_floors": 
False})
-    assert [name for name, on in enabled.items() if not on] == 
["upgrade-dependency-floors"]
+    assert [name for name, on in enabled.items() if not on] == [
+        "upgrade-dependency-floors",
+        "regenerate-provider-requirement-tables",
+    ]
 
 
 @pytest.mark.parametrize(

Reply via email to