Skip to content

[Bug]: Cancelled superseded CI run reports Coverage failure #26512

Closed

Description

@gouhongshen

Is there an existing issue for the same bug?

  • I searched matrixorigin/matrixone and matrixorigin/CI for coverage prerequisites, cancelled producers, coverage merge skips, and Draft-to-Ready coverage failures; no matching issue was found.

Branch Name

main

Commit ID

0b8b53d

Other Environment Information

Actual Behavior

Changing a PR from Draft to Ready starts a replacement workflow run and cancels the earlier run. In the cancelled run, required UT/BVT coverage producer jobs are cancelled, but Matrixone Utils CI / Coverage still starts and fails its prerequisite guard:

prerequisites_ready: false
expected_bvt_generation: 30620199557-1
::error::coverage merge skipped because at least one required producer was skipped or failed
Process completed with exit code 1.

The failed job did not check out or execute PR code. Its producer jobs had already been cancelled because the run was superseded. This leaves a red Coverage check attached to the PR even though the replacement Ready run is executing normally.

Failing run/job: https://github.com/matrixorigin/matrixone/actions/runs/30620199557/job/91122848686

Expected Behavior

A workflow run cancelled because it was superseded should not emit a failing Coverage result. The coverage merge job should remain cancelled/skipped/neutral when its prerequisites were cancelled, while preserving a real failure when required producers actually fail.

Steps to Reproduce

  1. Open a Draft PR that triggers MatrixOne ALL CI.
  2. Mark the PR Ready while the initial workflow run still has coverage producer jobs pending or running.
  3. Observe the initial run being cancelled and a replacement Ready run starting.
  4. Observe Matrixone Utils CI / Coverage in the cancelled run start with prerequisites_ready: false and fail immediately.

Additional information

The replacement workflow for the same head SHA (6961ff16d217e947618f43b92216c944f4559181) was run 30620241711. The failure is orchestration-related rather than a changed-code coverage failure: checkout, profile download, merge, and coverage-rate evaluation were all skipped in the failed job.

Activity

  1. self-assigned this
    on Jul 31, 2026
  2. added
    kind/bug
    and removed on Jul 31, 2026
  3. gouhongshen commented on Jul 31, 2026

    @gouhongshen
    ContributorAuthor

    PR #26527 reproduced this on 2026-07-31.

    The replacement run started at 15:28:17Z. Required producer jobs in the old run were cancelled beginning at 15:28:40Z; the Coverage job then started at 15:29:19Z with prerequisites_ready: false and failed with coverage merge skipped because at least one required producer was skipped or failed. The failed job did not check out or execute PR code, so this is another occurrence of the orchestration issue described here, not a changed-code coverage failure.

  4. gouhongshen commented on Jul 31, 2026

    @gouhongshen
    ContributorAuthor

    Per the PR CI recovery policy, run 30642056970 was rerun with --failed exactly once because its original attempt was 1. GitHub promoted it to attempt 2 and started the full producer set again. That rerun then cancelled the replacement run 30643017087's coverage producer at 15:37:31Z through the same workflow concurrency behavior.

    No further rerun will be requested for 30642056970 because it is now attempt 2. This also shows that rerunning the stale failed Coverage check is not an isolated recovery: it supersedes the healthy replacement run and repeats the underlying orchestration cycle.

  5. gouhongshen commented on Jul 31, 2026

    @gouhongshen
    ContributorAuthor

    Repeated-failure evidence from run 30642056970, attempt 2:

    This is a repeated occurrence on attempt 2, so it will not be rerun again.

  6. gouhongshen commented on Aug 1, 2026

    @gouhongshen
    ContributorAuthor

    PR #26560 reproduced this orchestration failure on 2026-08-01.

    The old run required UT, SCA, coverage-producer, and BVT jobs were cancelled after the replacement run started. The Coverage merge job then ran with prerequisites_ready: false and failed at Verify coverage prerequisites with coverage merge skipped because at least one required producer was skipped or failed. Checkout and all coverage processing steps were skipped, so no PR code executed in the failing job.

  7. gouhongshen commented on Aug 1, 2026

    @gouhongshen
    ContributorAuthor

    Per the PR CI recovery policy, superseded run 30699304272 was rerun with --failed exactly once because its original attempt was 1. GitHub promoted it to attempt 2. The rerun immediately caused the healthy replacement run 30699338603 producer jobs to be cancelled around 12:20Z through the same workflow concurrency behavior (including UT, SCA, BVT, and UT coverage). No further rerun will be requested for 30699304272 because it is now attempt 2.

  8. gouhongshen commented on Aug 1, 2026

    @gouhongshen
    ContributorAuthor

    The replacement run also reached the tracked failure after its producers were cancelled by the mandated rerun:

    The log again shows prerequisites_ready: false and the exact prerequisite-guard failure. Checkout and coverage processing were skipped. Because this workflow was still attempt 1, its failed jobs will be rerun exactly once; after that both involved workflow runs are attempt 2 and neither will be rerun again.

  9. gouhongshen commented on Aug 1, 2026

    @gouhongshen
    ContributorAuthor

    Repeated-failure evidence from run 30699304272, attempt 2:

    This is attempt 2, so it will not be rerun again.

  10. gouhongshen commented on Aug 3, 2026

    @gouhongshen
    ContributorAuthor

    Fixed by #26572 (commit c0dd903).

    The fix replaces the coverage merge caller condition from always() with cancellation-aware !cancelled(). Superseded workflows therefore no longer start a failing coverage merge after their required producers are cancelled, while a non-cancelled run with a genuine producer failure still reaches the existing prerequisite failure gate.

    Post-merge hosted validation: I inspected the 15 cancelled MatrixOne ALL CI runs present among the latest 200 workflow runs after the fix merged. None produced a cancellation-induced Coverage failure. Thirteen did not start the merge job, one completed Coverage successfully before the later cancellation, and the only failed Coverage job followed a real UT failure (TestReadCheckpoint panic) before cancellation.

    #26569 tracked the same failure mode and was closed by #26572, so this issue is resolved as well.

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

Metadata

Metadata

Assignees

Labels

deferredkind/bug

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions