Test a library change with every module downstream of it before it lands (MQ-7) #44

Merged
merge-queue merged 6 commits from anvil-groups into main 2026-11-30 23:15:50 -08:00
Owner

https://openproject.home.romaine.life/wp/MQ-7: the queue tests a Go library change with every module downstream of it before landing it, through pipeline-templates' new go/group.yml (romaine-life/pipeline-templates#337, which must land first).

Added

  • groups.go: at the front, once up to date with its base, the queue reads the files the PR changes from its clone (fetching the head first if the push's fetch hasn't come). A changed file that can change what users compile (not _test.go, .md, or under testdata) belongs to the deepest module above it; each such module with users in the graph is a library of the change. The queue starts go/group.yml on the PR's branch with pr and group (the libraries at the head, every downstream module at its default branch's commit, each repository's topics), asking Forgejo for the run it started.
  • Forgejo posts no commit status for a run started this way (v17 createCommitStatus), so the queue reports it itself in a new context merge-queue / group: pending linking the run as soon as it starts, then at the first look after the run ends success, or failure for a failed or cancelled run, which steps the PR aside as CI failed: merge-queue / group. The status is the whole record: a restart finds the run from it.
  • While any repository's clone isn't ready, the group isn't known whole: the front waits, naming it.
  • A change of only go.mod/go.sum (a dependency take-up) isn't group-tested, so tonight's take-up cascade isn't multiplied; the landing stage removes take-ups and this exception together.
  • Clone keeper: Ensure (fetch now if a head is missing), Rev, Changed, per-repository fetch lock, and each repository's topics. Client: DispatchRun (return_run_info), SetCheck, RunURL. Metric merge_queue_group_tests_total.

Left alone: every PR that changes no library with users lands exactly as before.

Tests (groups_test.go, against real git clones and the fake Forgejo): the group input; one start per head; waits while running; lands once passed; a failure and a cancelled run step it aside in the same look; tests/docs-only and take-up changes need no group; waits for a clone that isn't ready, then starts with it included.

🤖 Generated with Claude Code

https://openproject.home.romaine.life/wp/MQ-7: the queue tests a Go library change with every module downstream of it before landing it, through pipeline-templates' new `go/group.yml` (https://forgejo.romaine.life/romaine-life/pipeline-templates/pulls/337, which must land first). **Added** - `groups.go`: at the front, once up to date with its base, the queue reads the files the PR changes from its clone (fetching the head first if the push's fetch hasn't come). A changed file that can change what users compile (not `_test.go`, `.md`, or under `testdata`) belongs to the deepest module above it; each such module with users in the graph is a library of the change. The queue starts `go/group.yml` on the PR's branch with `pr` and `group` (the libraries at the head, every downstream module at its default branch's commit, each repository's topics), asking Forgejo for the run it started. - Forgejo posts no commit status for a run started this way (v17 `createCommitStatus`), so the queue reports it itself in a new context `merge-queue / group`: `pending` linking the run as soon as it starts, then at the first look after the run ends `success`, or `failure` for a failed or cancelled run, which steps the PR aside as `CI failed: merge-queue / group`. The status is the whole record: a restart finds the run from it. - While any repository's clone isn't ready, the group isn't known whole: the front waits, naming it. - A change of only `go.mod`/`go.sum` (a dependency take-up) isn't group-tested, so tonight's take-up cascade isn't multiplied; the landing stage removes take-ups and this exception together. - Clone keeper: `Ensure` (fetch now if a head is missing), `Rev`, `Changed`, per-repository fetch lock, and each repository's topics. Client: `DispatchRun` (`return_run_info`), `SetCheck`, `RunURL`. Metric `merge_queue_group_tests_total`. **Left alone**: every PR that changes no library with users lands exactly as before. Tests (`groups_test.go`, against real git clones and the fake Forgejo): the group input; one start per head; waits while running; lands once passed; a failure and a cancelled run step it aside in the same look; tests/docs-only and take-up changes need no group; waits for a clone that isn't ready, then starts with it included. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
The queue reports the group run itself: Forgejo posts no status for a dispatched run
All checks were successful
Suite cluster-service / check-manifests (pull_request) Has been skipped
Suite cluster-service / check-smoke (pull_request) Has been skipped
Suite cluster-service / publish (pull_request) Has been skipped
Suite go / reused-checks (pull_request) Successful in 16s
Suite go / scope (pull_request) Successful in 35s
Suite go / check-test-windows (pull_request) Has been skipped
Suite go / check-services (pull_request) Has been skipped
Suite default / check-fetches (pull_request) Has been skipped
Suite default / check-logs (pull_request) Successful in 26s
Suite cluster-service / scope (push) Has been skipped
Suite cluster-service / check-manifests (push) Has been skipped
Suite cluster-service / check-image (push) Has been skipped
Suite cluster-service / check-smoke (push) Has been skipped
Suite cluster-service / publish (push) Has been skipped
Suite cluster-service / reused-checks (push) Has been skipped
Suite cluster-service / scope (pull_request) Successful in 41s
Suite go / check-format (pull_request) Successful in 32s
Suite default / scope (pull_request) Successful in 39s
Suite cluster-service / reused-checks (pull_request) Successful in 25s
Suite default / check-rules (pull_request) Successful in 25s
Suite default / reused-checks (pull_request) Successful in 14s
Suite go / check-test-linux (pull_request) Successful in 58s
Suite cluster-service / check-image (pull_request) Successful in 59s
f5d681602e
Merge branch 'main' into anvil-groups
All checks were successful
Suite go / check-test-windows (pull_request) Has been skipped
Suite go / check-services (pull_request) Has been skipped
Suite cluster-service / scope (pull_request) Successful in 6s
Suite go / check-format (pull_request) Successful in 7s
Suite default / check-logs (pull_request) Successful in 6s
Suite go / check-test-linux (pull_request) Successful in 9s
Suite default / scope (pull_request) Successful in 6s
Suite go / scope (pull_request) Successful in 6s
Suite default / check-fetches (pull_request) Has been skipped
Suite cluster-service / check-smoke (pull_request) Has been skipped
Suite cluster-service / scope (push) Has been skipped
Suite cluster-service / check-manifests (push) Has been skipped
Suite cluster-service / check-image (push) Has been skipped
Suite cluster-service / check-smoke (push) Has been skipped
Suite cluster-service / publish (push) Has been skipped
Suite cluster-service / reused-checks (push) Has been skipped
Suite cluster-service / check-manifests (pull_request) Has been skipped
Suite cluster-service / publish (pull_request) Has been skipped
Suite default / check-rules (pull_request) Successful in 6s
Suite cluster-service / reused-checks (pull_request) Successful in 4s
merge-queue landed on main
Suite cluster-service / check-image (pull_request) Successful in 9s
Suite default / reused-checks (pull_request) Successful in 5s
Suite go / reused-checks (pull_request) Successful in 4s
6325696be9
merge-queue deleted branch anvil-groups 2026-11-30 23:15:50 -08:00
Sign in to join this conversation.
No reviewers
No labels
queue
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
romaine-life/merge-queue!44
No description provided.