Skip to content

ci(merge-queue): a shard that never got a runner is not a test failure #21933

Description

@objectstack-fleet

Requested by the maintainer in Claude Code session session_018zT8d8NpiQ1ExhuNd5TxY6, 2026-10-06 (「两张卡都开」).

What happened

On 2026-10-05, PR #21872 was removed from the merge queue twice with CI_FAILURE, and nothing in it was failing:

  • Run 37371558492 and its siblings: the guard jobs were cancelled with "The job was not acquired by Runner of type hosted even after multiple attempts".
  • Run 37374282440: Test Core (5/6) was cancelled with no runner assigned (empty runner_name, zero steps). The aggregator then reported "1 of 6 declared shard(s) of test published no positive attestation".

The same day, PR #21877's head saw 13 cancelled jobs before any test body ran.

Each time, a person had to open the jobs to tell a runner outage from a test failure before re-queuing. The merge-queue triage comment (merge-queue-triage workflow, #4859) could not tell them apart either ("日志不可读").

Proposal

  1. Classify. When a required job ends cancelled with no runner assigned (runner_name empty, no steps run), or with the "not acquired by Runner" annotation, label the build infra:no-runner instead of a test failure. The triage comment then names it as such.
  2. Re-queue once, automatically. For a build whose only red is infra:no-runner, re-queue the PR once. Never re-queue a second time on the same head, and never re-queue a real failure. A second no-runner failure goes to a person.
  3. Keep the attestation rule. A shard that never ran still does not count as passing (CI 聚合门禁把合并队列重建的 aggregate result: abandoned 判成红 —— 在队 PR 零测试失败被踢出(ci.yml 两处白名单缺 abandoned) #6082). This only changes how the red is classified and handled. It does not change whether the build is green.

Done when

  • A synthetic no-runner cancellation is classified and re-queued once. A real shard failure is not re-queued.
  • The triage comment names the class.
  • The workflow has a test or a dry-run fixture for both cases.

Generated by Claude Code

Activity

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

Metadata

Metadata

Assignees

Labels

area:devpathThe road — create, dev, verify, publish/install, connect an agent, iteratedomain:devxpriority:p2Medium: important, M3tooling

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions