Skip to content

Report EC2 Spot interruptions on pull requests and keep them out of Slack - #75615

Merged
potiuk merged 1 commit into
mainfrom
spot-interruption-notice
Oct 25, 2026
Merged

potiuk merged 1 commit into
mainfrom
spot-interruption-notice

Conversation

@potiuk

@potiuk potiuk commented Oct 25, 2026

Copy link
Copy Markdown
Member

Jobs on the self-hosted RunsOn runners fail with exit code 137 when AWS reclaims their Spot instance. Nothing in the job log says why, so it looks like a broken test or an out-of-memory kill, although RunsOn re-runs the job by itself once the run finishes. Today's canary and #75612 were both hit.

  • spot-interruption-notice.yml checks the newest "Tests (AMD)" run of each PR every 10 minutes, including runs still in progress, and keeps one comment on the PR: which jobs were interrupted and that RunsOn re-runs them, then how the re-run ended. It runs on a schedule, so no PR run gets write access.
  • A canary's notify-slack no longer posts failures that are only Spot interruptions RunsOn will retry. It posts for RunsOn's re-run instead (which it previously never ran for, so recoveries went unreported), and still posts when RunsOn gives up after attempt 3.
  • An interruption is recognised only by RunsOn's annotation on a job that ran on a RunsOn runner, so real failures and annotations a PR's own workflow could add are never treated as one.
  • The API budget of the polling is measured and documented in 05_workflows.md: about 2% of the repository's GITHUB_TOKEN limit.

Was generative AI tooling used to co-author this PR?
  • Yes — Claude Opus 5

Generated-by: Claude Opus 5 following the guidelines

…lack

Jobs on the self-hosted RunsOn runners fail with exit code 137 when AWS
reclaims their Spot instance. Nothing in the job's log says why, so the
failure looks like a broken test or an out-of-memory kill, although RunsOn
re-runs the job by itself once the run finishes.

A pull request should say so as soon as it happens, and the canary should
not page anyone on Slack until RunsOn has given up retrying. The Slack
notification also never reported how RunsOn's re-run ended, because it only
ran for the first attempt.

Generated-by: Claude Opus 5
@potiuk
potiuk merged commit 4386cb1 into main Oct 25, 2026
143 of 154 checks passed
@potiuk
potiuk deleted the spot-interruption-notice branch October 25, 2026 18:18
@github-actions

Copy link
Copy Markdown
Contributor

Backport failed to create: v3-4-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-4-test Commit Link

You can attempt to backport this manually by running:

cherry_picker 4386cb1 v3-4-test

This should apply the commit to the v3-4-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 Oct 25, 2026
…, #75615) (#75617)

* Keep a Breeze test's --dry-run from leaking into later tests (#75589)

The dry-run, verbose and forced-answer options are process-wide, so a
test invoking a command with --dry-run made run_command return empty
output for every later test on the same xdist worker. Which tests failed
depended on how xdist distributed them, so the Breeze unit tests failed
intermittently, as in the scheduled ARM run.

Generated-by: Claude Opus 5

(cherry picked from commit 0c1fa8e)

* Run shared distribution tests in a single CI job (#74566)

* Run shared distribution tests in a single CI job

The shared distributions matrix starts one runner per directory in
shared/ (14 today) on every PR. Each leg spends ~15s on checkout and uv
setup to run ~2-4s of tests, and the fan-out takes 14 of the 20
concurrent jobs ASF allows per workflow.

Running the distributions sequentially in one job keeps the same
coverage, reports every failing distribution, and frees those slots.

* Run each shared distribution with uv --exact for isolation

* Wrap the shared distributions test loop line to satisfy yamllint

Generated-by: Claude Opus 5

---------

Co-authored-by: Jarek Potiuk <jarek@potiuk.com>

(cherry picked from commit 6b42e65)

* Run maintainer and canary CI on self-hosted RunsOn runners (#74889)

This PR implements AIP-118 for integrating self-hosted runners in Apache Airflow's CI, utilizing the project's AWS instance and runs-on.com's runners.

(cherry picked from commit b5bc253)
Generated-by: Claude Opus 5

* Check newsfragment PR numbers in static checks instead of a separate workflow (#75612)

* Check newsfragment PR numbers in static checks instead of a separate workflow

The separate workflow ran outside the fork CI gate (AIP-120), needed its own
required check, and needed its own approval for first-time contributors.
As part of the existing newsfragment hook it runs wherever static checks
run, in project CI and in a contributor's fork, and fails CI passed like any
other static check.

A newsfragment is usually written before its pull request exists, so a
local run cannot know the right number and accepts any.

Generated-by: Claude Opus 5

* Address review of the newsfragment PR number check

A pull request inside a fork carries the fork's number, so only apache/airflow pull requests are checked. A GitHub API error is reported without a traceback, and the instructions say who re-runs the checks when CI runs in the contributor's fork.

Generated-by: Claude Opus 5

(cherry picked from commit 757898c)

The documentation conflicts were resolved by keeping the release branch's text and
updating only its sentences about the newsfragment check.

* Report EC2 Spot interruptions on pull requests and keep them out of Slack (#75615)

Jobs on the self-hosted RunsOn runners fail with exit code 137 when AWS
reclaims their Spot instance. Nothing in the job's log says why, so the
failure looks like a broken test or an out-of-memory kill, although RunsOn
re-runs the job by itself once the run finishes.

A pull request should say so as soon as it happens, and the canary should
not page anyone on Slack until RunsOn has given up retrying. The Slack
notification also never reported how RunsOn's re-run ended, because it only
ran for the first attempt.

Generated-by: Claude Opus 5

(cherry picked from commit 4386cb1)
@potiuk potiuk added this to the Airflow 3.4.0 milestone Oct 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants