Apache Software Foundation / SeaTunnel
Merged upstreamReliabilityMerged Sep 28, 2026

Correct mirrored build status across reruns

Reworked the scheduled Build-check mirror to create one check per rerun attempt, refine cancelled outcomes from job evidence, paginate duplicate check names safely, and stop repeatedly patching unchanged results.

apache/seatunnel · #12473

CI status correctness

SeaTunnel's mirrored Build check now represents the current rerun attempt, distinguishes failures from timeouts and cancellations, and avoids thousands of no-op GitHub API writes.

Problem

GitHub does not move a completed check back to in-progress, so reruns continued showing the previous result. Timed-out runs appeared merely cancelled, and a broken URL comparison caused 10,708 patches across 80 updater runs, 97% of which changed nothing.

Approach

Selects the newest Build check across complete pagination, creates a replacement only for a new attempt, derives failure, timed-out, or cancelled from jobs and annotations, records attempt timestamps, skips finalized matches, and serializes updater ticks with workflow concurrency.

Impact and scope

  • Keeps the pull request's visible Build status aligned with the active or most recent rerun instead of displaying stale failure state.
  • Separates genuine test failures, execution timeouts, and user cancellations so contributors and maintainers receive the right signal.
  • Eliminates most repeated API writes by comparing status and conclusion and treating an already-final check as complete.
  • The scheduled upstream workflow could not be exercised against live Apache pull requests before merge, so post-merge updater logs remain the end-to-end confirmation.

Validation

  • A Node 20 harness covered 33 rerun, duplicate-check, pagination, cancellation, timeout, queued-parent, and repeat-tick scenarios; current development code passed 9, the first revision passed 21, and the final change passed all 33.
  • A fork probe confirmed GitHub's behavior for duplicate Build checks, ignored completed-to-in-progress patches, and explicit started and completed timestamps.
  • All four hosted checks passed; review feedback was iterated before an upstream contributor approved the final authored change.