Closes #249. A landing lands the commit the combined result published — same tree, same workflow, same job, already run for the base branch. The push that moved the branch then queued all of it again, so one commit showed up twice in the run list and the runner did the same work twice.
The rule
Queueing asks whether a combined result for this branch already ran and passed this job at this commit. If it did, the push owes nothing: the run that tested the landing stays the one run for it.
ci/runs:CombinedResultPassed(repo, branch, sha, workflow, job)— one indexed query onruns_repo_sha, no scan.server/ci.go: asked only for a push to the branch itself. A tag is a release build of its own, an event run is a new occurrence of one, and the candidate’s own queue call is the one being reused.
The exception
A job that deploys the site still runs. A combined result never deploys — it is not on the branch yet — so publishing the site is work it did not do. Repositories without a pages job, which is most of them, lose the duplicate entirely; a repository with one keeps a second run that genuinely does something different.
Not in this change
A fast-forward landing still builds the head on the base branch after the head’s own branch built it. Those runs select workflows by branch, so they are not the same work by construction. Only a combined result is queued as “a normal run for the base branch”, and that is what makes this dedupe exact rather than a guess about two branches meaning the same thing.
Testing
ci/runs: the query matches only a green run at the same repository, branch, commit, workflow and job; queued, running, failed, canceled and error runs are not evidence.server: a white-box reconciliation test — a successful combined result at the branch tip means the push queues nothing, the surviving run is the candidate one, and the branch cursor still moves so the tip is not owed forever; and a job withpages:still queues its site run with the right path.
vole workflow run verify passes (format, vet, build, licenses, govulncheck,
packages, deployment files, links, race suite), on a branch rebased onto the merged
#246 and #247 work.
Docs: docs/change-requests.md says the landing no longer queues the same jobs again
and names the site exception.