Skip to content

[Experimental] Split ci-amd-arm.yml into ARM canary and AMD per-PR workflows#66348

Merged
potiuk merged 2 commits into
apache:mainfrom
potiuk:split-ci-arm-amd-workflows
May 7, 2026
Merged

[Experimental] Split ci-amd-arm.yml into ARM canary and AMD per-PR workflows#66348
potiuk merged 2 commits into
apache:mainfrom
potiuk:split-ci-arm-amd-workflows

Conversation

@potiuk

@potiuk potiuk commented May 4, 2026

Copy link
Copy Markdown
Member

Summary

The combined ci-amd-arm.yml alternated ARM and AMD on the canary slot via a
runtime RUNNERS_TYPE_CROSS_MAPPING lookup of the previous workflow run's
labels. That worked but tied the two architectures together — one canary slot
had to flip between them, badges showed whichever ran last, notifications
spoke for both, and a runtime API call decided the platform on every push.

This change splits the file into a reusable pipeline + two thin wrappers:

  • _ci-pipeline.yml — reusable workflow (workflow_call) with the
    entire pipeline. Takes platform and runner-type as inputs;
    build-info echoes the inputs instead of computing them via
    cross-mapping. Single source of truth — no per-platform duplication.
  • ci-arm.yml — slim wrapper. Schedule (canary cron) +
    workflow_dispatch only. Calls _ci-pipeline.yml with
    platform: linux/arm64.
  • ci-amd.yml — slim wrapper. pull_request + push (to v3-N-test etc)
    • workflow_dispatch. Calls _ci-pipeline.yml with
      platform: linux/amd64. No schedule for now; ARM keeps the canary
      slot. Add a schedule: block here if/when AMD should also act as a
      scheduled canary — the two workflows run in parallel with separate
      concurrency groups.

The runtime cross-mapping in selective_checks.runner_type is left in place
because is_disabled_integration still consumes it; the API lookup against
the now-removed ci-amd-arm.yml returns nothing and falls back to AMD,
which is harmless. Removing the cross-mapping entirely is a follow-up.

Reference updates (every consumer of the old file name)

  • README.md and dev/update_github_branch_config.py: badges → ci-amd.yml
    (the workflow that runs on every push to main)
  • .github/workflows/ci-notification.yml: workflow-idci-amd.yml
  • .github/workflows/e2e-flaky-tests-report.yml: WORKFLOW_NAME
    ci-amd.yml
  • scripts/ci/analyze_e2e_flaky_tests.py: default WORKFLOW_NAME
    ci-amd.yml
  • dev/README_AIRFLOW3_DEV.md, dev/README_RELEASE_AIRFLOW.md: release-cut
    verification URL → ci-amd.yml
  • generated/PYPI_README.md: regenerated from README.md
  • .github/workflows/update-constraints-on-push*.yml,
    release_dockerhub_image.yml: comments referring back to the old file →
    _ci-pipeline.yml

Test plan

  • prek run yamllint clean on all changed workflow files
  • prek run zizmor clean (template-injection on the print-platform
    job's inputs.platform was hoisted to env; secrets: inherit replaced
    with explicit DOCS_AWS_* / SLACK_BOT_TOKEN forwarding)
  • prek run --files <changed> clean across all hooks
  • All 162 test_selective_checks.py tests pass (the runner_type
    tests still pass since they mock requests.get and don't depend on the
    real workflow file existing)
  • Smoke-test in CI: opening this PR will trigger ci-amd.yml. The ARM
    canary will fire on its next scheduled cron tick — if both look healthy,
    ready for review.

Why draft

Posting as draft for an initial review of the architecture before letting
CI exercise it for the first time. Once the AMD run on this PR completes
green, I'll mark it ready for review.


Was generative AI tooling used to co-author this PR?
  • Yes — Claude Code (Opus 4.7)

Generated-by: Claude Code (Opus 4.7) following the guidelines

@potiuk
potiuk marked this pull request as ready for review May 4, 2026 16:03
@potiuk potiuk changed the title Split ci-amd-arm.yml into ARM canary and AMD per-PR workflows [Experimental] Split ci-amd-arm.yml into ARM canary and AMD per-PR workflows May 4, 2026
@potiuk
potiuk force-pushed the split-ci-arm-amd-workflows branch from c3a7012 to 32c769e Compare May 4, 2026 16:12
potiuk added 2 commits May 7, 2026 04:32
… wrappers

Replaces the combined ci-amd-arm.yml workflow with two thin wrappers carrying
the full pipeline inline:

- ci-arm.yml: schedule (canary cron) + workflow_dispatch only;
  runs on linux/arm64.
- ci-amd.yml: pull_request + push (to v3-N-test etc) + workflow_dispatch;
  runs on linux/amd64. No schedule for now; ARM keeps the canary slot.

Each wrapper carries the full pipeline jobs identically except for platform /
runner-type / triggers, so per-job UI grouping is preserved on the GitHub
Actions page. The runtime cross-mapping in selective_checks.runner_type is
left in place because is_disabled_integration still consumes it; the API
lookup against the now-removed ci-amd-arm.yml falls back to AMD harmlessly.

References to the old file name are updated in:
README.md, dev/update_github_branch_config.py, ci-notification.yml,
e2e-flaky-tests-report.yml, scripts/ci/analyze_e2e_flaky_tests.py,
dev/README_AIRFLOW3_DEV.md, dev/README_RELEASE_AIRFLOW.md,
generated/PYPI_README.md, update-constraints-on-push*.yml,
release_dockerhub_image.yml.
The two CI workflow files are physical copies of each other (GH Actions
has no cross-file YAML include) — they should differ only in:

- header intro comment
- workflow name (ARM vs AMD)
- triggers (schedule vs pull_request+push)
- concurrency group prefix
- build-info platform / runner-type outputs
- print-platform job name + echo

Drift outside this set is a bug. The new
`scripts/ci/prek/check_ci_workflows_in_sync.py` normalizes both files
against the documented divergences (regex line rules + arch-only block
removals) and asserts the rest matches byte-for-byte. Wired up as a
local prek hook gated on either workflow file changing.

Local UX: when run interactively, the script also diffs each file
against `upstream/main` (falls back to `origin/main`, then `main`) and
attributes the drift — "only ci-arm.yml changed since baseline; mirror
to ci-amd.yml" with the exact diff to copy, OR "add to LINE_RULES /
ARM_ONLY_BLOCK in this script if intentional". Falls back to the
non-attribution view in CI / non-TTY runs. Set `FORCE_INTERACTIVE=1`
to opt in from a non-TTY shell.
@potiuk
potiuk force-pushed the split-ci-arm-amd-workflows branch from 32c769e to cb7492c Compare May 7, 2026 02:33

@jscheffl jscheffl left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would be good with this. But also have no strong opinion. That that YAML can not include, would save a lot of redundant code.. but with tooling as you provided is acceptable burden.

@potiuk
potiuk merged commit 8f93637 into apache:main May 7, 2026
143 checks passed
@potiuk
potiuk deleted the split-ci-arm-amd-workflows branch May 7, 2026 23:07
@github-actions

github-actions Bot commented May 7, 2026

Copy link
Copy Markdown
Contributor

Backport failed to create: v3-2-test. View the failure log Run details

Note: As of Merging PRs targeted for Airflow 3.X
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 Slack channel.

Status Branch Result
v3-2-test Commit Link

You can attempt to backport this manually by running:

cherry_picker 8f93637 v3-2-test

This should apply the commit to the v3-2-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:

cherry_picker --continue

If you don't have cherry-picker installed, see the installation guide.

potiuk added a commit that referenced this pull request May 10, 2026
…rkflows (#66348) (#66664)

* Split ci-amd-arm.yml into ci-arm.yml (canary) and ci-amd.yml (per-PR) wrappers

Replaces the combined ci-amd-arm.yml workflow with two thin wrappers carrying
the full pipeline inline:

- ci-arm.yml: schedule (canary cron) + workflow_dispatch only;
  runs on linux/arm64.
- ci-amd.yml: pull_request + push (to v3-N-test etc) + workflow_dispatch;
  runs on linux/amd64. No schedule for now; ARM keeps the canary slot.

Each wrapper carries the full pipeline jobs identically except for platform /
runner-type / triggers, so per-job UI grouping is preserved on the GitHub
Actions page. The runtime cross-mapping in selective_checks.runner_type is
left in place because is_disabled_integration still consumes it; the API
lookup against the now-removed ci-amd-arm.yml falls back to AMD harmlessly.

References to the old file name are updated in:
README.md, dev/update_github_branch_config.py, ci-notification.yml,
e2e-flaky-tests-report.yml, scripts/ci/analyze_e2e_flaky_tests.py,
dev/README_AIRFLOW3_DEV.md, dev/README_RELEASE_AIRFLOW.md,
generated/PYPI_README.md, update-constraints-on-push*.yml,
release_dockerhub_image.yml.

* Add prek hook that asserts ci-arm.yml and ci-amd.yml stay in sync

The two CI workflow files are physical copies of each other (GH Actions
has no cross-file YAML include) — they should differ only in:

- header intro comment
- workflow name (ARM vs AMD)
- triggers (schedule vs pull_request+push)
- concurrency group prefix
- build-info platform / runner-type outputs
- print-platform job name + echo

Drift outside this set is a bug. The new
`scripts/ci/prek/check_ci_workflows_in_sync.py` normalizes both files
against the documented divergences (regex line rules + arch-only block
removals) and asserts the rest matches byte-for-byte. Wired up as a
local prek hook gated on either workflow file changing.

Local UX: when run interactively, the script also diffs each file
against `upstream/main` (falls back to `origin/main`, then `main`) and
attributes the drift — "only ci-arm.yml changed since baseline; mirror
to ci-amd.yml" with the exact diff to copy, OR "add to LINE_RULES /
ARM_ONLY_BLOCK in this script if intentional". Falls back to the
non-attribution view in CI / non-TTY runs. Set `FORCE_INTERACTIVE=1`
to opt in from a non-TTY shell.

(cherry picked from commit 8f93637)
potiuk added a commit that referenced this pull request May 10, 2026
…llision (#66662)

PR #66348 split the combined ci-amd-arm.yml into per-platform wrappers and
intentionally deferred re-adding a schedule trigger to ci-amd.yml ('No
schedule for now; ARM keeps the canary slot. Add a schedule: block here
if/when AMD should also act as a scheduled canary'). As a result:

- The AMD 'Tests (AMD)' badge on the README pointed at a workflow that
  hadn't run on main since 2025-10-25 (it now only runs on PRs and
  release-branch pushes), so the badge was stale.
- The notify-slack job at the bottom of ci-amd.yml is gated on
  github.event_name == 'schedule' and was therefore dead code: there
  was no schedule trigger left to fire it.
- main on AMD had no scheduled CI monitor at all (ci-notification.yml
  only watches v3-2-test x ci-amd.yml, and the comment there assumes
  ARM is reported by its own notify-slack).

This change:

1. Restores the previous AMD canary cron in ci-amd.yml at minute :58 of
   the same hours ARM uses, so the two scheduled runs don't compete for
   runners at exactly the same minute.
2. Splits the README build-status row for main into two badges (AMD and
   ARM), drops the obsolete 2.x row (still using the legacy ci.yml), and
   keeps 3.x AMD-only (ARM has no v3-2-test schedule). Click-throughs go
   to the workflow page rather than the catch-all /actions URL.
3. Disambiguates the slack-state artifact names that ci-amd.yml,
   ci-arm.yml, and ci-image-checks.yml share. Before this PR the latent
   collision did not bite (AMD's notify-slack never fired); restoring
   the AMD schedule activates it. Each platform now writes its own
   slack-state-{tests,inventory}-<branch>-{amd,arm} artifact so the
   de-dup tracker in scripts/ci/slack_notification_state.py keeps
   independent state per platform.
4. Updates scripts/ci/prek/check_ci_workflows_in_sync.py to allow the
   new AMD-only schedule block and the per-platform artifact-name
   suffix as documented divergences.

generated/PYPI_README.md is regenerated automatically by the
generate-pypi-readme prek hook to mirror README.md.
potiuk added a commit that referenced this pull request May 10, 2026
…llision (#66662) (#66665)

PR #66348 split the combined ci-amd-arm.yml into per-platform wrappers and
intentionally deferred re-adding a schedule trigger to ci-amd.yml ('No
schedule for now; ARM keeps the canary slot. Add a schedule: block here
if/when AMD should also act as a scheduled canary'). As a result:

- The AMD 'Tests (AMD)' badge on the README pointed at a workflow that
  hadn't run on main since 2025-10-25 (it now only runs on PRs and
  release-branch pushes), so the badge was stale.
- The notify-slack job at the bottom of ci-amd.yml is gated on
  github.event_name == 'schedule' and was therefore dead code: there
  was no schedule trigger left to fire it.
- main on AMD had no scheduled CI monitor at all (ci-notification.yml
  only watches v3-2-test x ci-amd.yml, and the comment there assumes
  ARM is reported by its own notify-slack).

This change:

1. Restores the previous AMD canary cron in ci-amd.yml at minute :58 of
   the same hours ARM uses, so the two scheduled runs don't compete for
   runners at exactly the same minute.
2. Splits the README build-status row for main into two badges (AMD and
   ARM), drops the obsolete 2.x row (still using the legacy ci.yml), and
   keeps 3.x AMD-only (ARM has no v3-2-test schedule). Click-throughs go
   to the workflow page rather than the catch-all /actions URL.
3. Disambiguates the slack-state artifact names that ci-amd.yml,
   ci-arm.yml, and ci-image-checks.yml share. Before this PR the latent
   collision did not bite (AMD's notify-slack never fired); restoring
   the AMD schedule activates it. Each platform now writes its own
   slack-state-{tests,inventory}-<branch>-{amd,arm} artifact so the
   de-dup tracker in scripts/ci/slack_notification_state.py keeps
   independent state per platform.
4. Updates scripts/ci/prek/check_ci_workflows_in_sync.py to allow the
   new AMD-only schedule block and the per-platform artifact-name
   suffix as documented divergences.

generated/PYPI_README.md is regenerated automatically by the
generate-pypi-readme prek hook to mirror README.md.

(cherry picked from commit 022e35d)
jason810496 pushed a commit to jason810496/airflow that referenced this pull request May 11, 2026
…rkflows (apache#66348)

* Split ci-amd-arm.yml into ci-arm.yml (canary) and ci-amd.yml (per-PR) wrappers

Replaces the combined ci-amd-arm.yml workflow with two thin wrappers carrying
the full pipeline inline:

- ci-arm.yml: schedule (canary cron) + workflow_dispatch only;
  runs on linux/arm64.
- ci-amd.yml: pull_request + push (to v3-N-test etc) + workflow_dispatch;
  runs on linux/amd64. No schedule for now; ARM keeps the canary slot.

Each wrapper carries the full pipeline jobs identically except for platform /
runner-type / triggers, so per-job UI grouping is preserved on the GitHub
Actions page. The runtime cross-mapping in selective_checks.runner_type is
left in place because is_disabled_integration still consumes it; the API
lookup against the now-removed ci-amd-arm.yml falls back to AMD harmlessly.

References to the old file name are updated in:
README.md, dev/update_github_branch_config.py, ci-notification.yml,
e2e-flaky-tests-report.yml, scripts/ci/analyze_e2e_flaky_tests.py,
dev/README_AIRFLOW3_DEV.md, dev/README_RELEASE_AIRFLOW.md,
generated/PYPI_README.md, update-constraints-on-push*.yml,
release_dockerhub_image.yml.

* Add prek hook that asserts ci-arm.yml and ci-amd.yml stay in sync

The two CI workflow files are physical copies of each other (GH Actions
has no cross-file YAML include) — they should differ only in:

- header intro comment
- workflow name (ARM vs AMD)
- triggers (schedule vs pull_request+push)
- concurrency group prefix
- build-info platform / runner-type outputs
- print-platform job name + echo

Drift outside this set is a bug. The new
`scripts/ci/prek/check_ci_workflows_in_sync.py` normalizes both files
against the documented divergences (regex line rules + arch-only block
removals) and asserts the rest matches byte-for-byte. Wired up as a
local prek hook gated on either workflow file changing.

Local UX: when run interactively, the script also diffs each file
against `upstream/main` (falls back to `origin/main`, then `main`) and
attributes the drift — "only ci-arm.yml changed since baseline; mirror
to ci-amd.yml" with the exact diff to copy, OR "add to LINE_RULES /
ARM_ONLY_BLOCK in this script if intentional". Falls back to the
non-attribution view in CI / non-TTY runs. Set `FORCE_INTERACTIVE=1`
to opt in from a non-TTY shell.
vatsrahul1001 pushed a commit that referenced this pull request May 20, 2026
…rkflows (#66348) (#66664)

* Split ci-amd-arm.yml into ci-arm.yml (canary) and ci-amd.yml (per-PR) wrappers

Replaces the combined ci-amd-arm.yml workflow with two thin wrappers carrying
the full pipeline inline:

- ci-arm.yml: schedule (canary cron) + workflow_dispatch only;
  runs on linux/arm64.
- ci-amd.yml: pull_request + push (to v3-N-test etc) + workflow_dispatch;
  runs on linux/amd64. No schedule for now; ARM keeps the canary slot.

Each wrapper carries the full pipeline jobs identically except for platform /
runner-type / triggers, so per-job UI grouping is preserved on the GitHub
Actions page. The runtime cross-mapping in selective_checks.runner_type is
left in place because is_disabled_integration still consumes it; the API
lookup against the now-removed ci-amd-arm.yml falls back to AMD harmlessly.

References to the old file name are updated in:
README.md, dev/update_github_branch_config.py, ci-notification.yml,
e2e-flaky-tests-report.yml, scripts/ci/analyze_e2e_flaky_tests.py,
dev/README_AIRFLOW3_DEV.md, dev/README_RELEASE_AIRFLOW.md,
generated/PYPI_README.md, update-constraints-on-push*.yml,
release_dockerhub_image.yml.

* Add prek hook that asserts ci-arm.yml and ci-amd.yml stay in sync

The two CI workflow files are physical copies of each other (GH Actions
has no cross-file YAML include) — they should differ only in:

- header intro comment
- workflow name (ARM vs AMD)
- triggers (schedule vs pull_request+push)
- concurrency group prefix
- build-info platform / runner-type outputs
- print-platform job name + echo

Drift outside this set is a bug. The new
`scripts/ci/prek/check_ci_workflows_in_sync.py` normalizes both files
against the documented divergences (regex line rules + arch-only block
removals) and asserts the rest matches byte-for-byte. Wired up as a
local prek hook gated on either workflow file changing.

Local UX: when run interactively, the script also diffs each file
against `upstream/main` (falls back to `origin/main`, then `main`) and
attributes the drift — "only ci-arm.yml changed since baseline; mirror
to ci-amd.yml" with the exact diff to copy, OR "add to LINE_RULES /
ARM_ONLY_BLOCK in this script if intentional". Falls back to the
non-attribution view in CI / non-TTY runs. Set `FORCE_INTERACTIVE=1`
to opt in from a non-TTY shell.

(cherry picked from commit 8f93637)
vatsrahul1001 pushed a commit that referenced this pull request May 20, 2026
…llision (#66662) (#66665)

PR #66348 split the combined ci-amd-arm.yml into per-platform wrappers and
intentionally deferred re-adding a schedule trigger to ci-amd.yml ('No
schedule for now; ARM keeps the canary slot. Add a schedule: block here
if/when AMD should also act as a scheduled canary'). As a result:

- The AMD 'Tests (AMD)' badge on the README pointed at a workflow that
  hadn't run on main since 2025-10-25 (it now only runs on PRs and
  release-branch pushes), so the badge was stale.
- The notify-slack job at the bottom of ci-amd.yml is gated on
  github.event_name == 'schedule' and was therefore dead code: there
  was no schedule trigger left to fire it.
- main on AMD had no scheduled CI monitor at all (ci-notification.yml
  only watches v3-2-test x ci-amd.yml, and the comment there assumes
  ARM is reported by its own notify-slack).

This change:

1. Restores the previous AMD canary cron in ci-amd.yml at minute :58 of
   the same hours ARM uses, so the two scheduled runs don't compete for
   runners at exactly the same minute.
2. Splits the README build-status row for main into two badges (AMD and
   ARM), drops the obsolete 2.x row (still using the legacy ci.yml), and
   keeps 3.x AMD-only (ARM has no v3-2-test schedule). Click-throughs go
   to the workflow page rather than the catch-all /actions URL.
3. Disambiguates the slack-state artifact names that ci-amd.yml,
   ci-arm.yml, and ci-image-checks.yml share. Before this PR the latent
   collision did not bite (AMD's notify-slack never fired); restoring
   the AMD schedule activates it. Each platform now writes its own
   slack-state-{tests,inventory}-<branch>-{amd,arm} artifact so the
   de-dup tracker in scripts/ci/slack_notification_state.py keeps
   independent state per platform.
4. Updates scripts/ci/prek/check_ci_workflows_in_sync.py to allow the
   new AMD-only schedule block and the per-platform artifact-name
   suffix as documented divergences.

generated/PYPI_README.md is regenerated automatically by the
generate-pypi-readme prek hook to mirror README.md.

(cherry picked from commit 022e35d)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants