Skip to content

test-containers-lectures: alert on a cancelled run only when no newer run exists #286

Closed

Description

@mmcky

test-containers-lectures.yml's Report failure job files the tracking issue whenever its test job concludes failure or cancelled. cancelled has to alert, because a leg stopped by timeout-minutes concludes cancelled, not failed: the August sweeps that hit the 120-minute ceiling went unreported for three weeks before it did (#140, #141). The cost, which the job's comment accepts, is a false alarm whenever the workflow's cancel-in-progress supersedes a run. #249 was one: on 2026-11-05 a container build landed during a matrix run, and all seven unfinished legs were cancelled after 8 minutes.

#274 (#142, phase 2) gives build-containers.yml's alert a narrower rule, which the maintainer chose on 2026-11-07: a failure always alerts, and a run with a cancelled job but no failed one alerts only when no newer run of the workflow exists on its branch. If the list of runs can't be read, it alerts.

The maintainer decided on 2026-11-09 that the lecture matrix takes the same rule. A leg that times out with no newer run behind it still alerts. A run superseded by a newer one doesn't, and the newer run reports for itself.

The change:

  • one helper under scripts/, with a self-test, that decides "a newer run of this workflow exists on this branch", called by both workflows' alert jobs, so the two rules can't drift apart. It goes in the gate's container MUST_RUN list beside scripts/promote-image.sh;
  • the lecture matrix's Report failure job calls it before filing, and its comment explains the narrower rule;
  • CI only: no action changes, so no CHANGELOG entry.

It builds on #274, so it waits for that to merge, and it goes with #141's per-leg durations, which change the same workflow.

Claude Code (on behalf of mmcky), organiser session

Activity

  1. added
    infrastructure
    on Nov 9, 2026
  2. mmcky commented on Nov 9, 2026

    @mmcky
    ContributorAuthor

    Checked against main at 5a80d5c and #274 at a2b1ce5: the proposal holds, and #274 now carries its first half. scripts/newer-runs.sh counts the newer runs of a workflow on a branch, with a self-test in validate-containers.yml and an entry in the gate's MUST_RUN, and build-containers.yml's alert calls it. So the PR for this issue changes only the lecture matrix's Report failure job, its comment, and the CONTAINER-VALIDATION.md bullet. No build-containers.yml edit, so its merge rebuilds no image.

    The branch is the right one to count on. The matrix's concurrency group is test-containers-lectures-${{ github.ref }}, and for schedule and workflow_run runs github.ref is the default branch: every such run so far (65 to 79) is recorded on main. So the job passes github.ref_name, as build-containers.yml does. #249 was two supersedes, runs 75 and 76, and the new rule files neither. A leg that times out still files, since nothing newer has started, and a failed leg always files.

    The superseding run reports for itself, except when it's a dispatch: dispatches don't file, since someone is watching them. When a dispatch on main supersedes a scheduled run, neither files. That matches #274's rule for the image builds. Re-running an old run during a newer one can still file a spare issue, but it errs towards alerting.

    CI only: no CHANGELOG entry. It opens after #274 merges. Since it touches test-containers-lectures.yml, it merges on the organiser's word while the v0.17.0 matrix run is pending.

    The maintainer's decision, 2026-11-10: a run superseded by a dispatch files nothing, as under #274's rule, since the dispatch covers it and someone is watching it. This issue and #141's per-leg durations go in separate PRs.

    Claude Code (on behalf of mmcky), organiser session; the check by the mini:actions-containers session

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    infrastructure

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions