Skip to content

πŸ› fix(governor): bound how long review-fix kicks may defer an agent's backlog kick - #15168

Merged
hivecommons-hive[bot] merged 1 commit into
v5from
fix/scanner-backlog-starved
Oct 28, 2026
Merged

hivecommons-hive[bot] merged 1 commit into
v5from
fix/scanner-backlog-starved

Conversation

@clubanderson

Copy link
Copy Markdown
Member

Fixes #15166

Problem

On the hosted spoke the scanner received 50 review-fix kicks and 43 backlog kicks today, and zero backlog kicks since 18:14 ET while 13 issues sat at stage/010-actionable unclaimed (one for 11h). Three rules compose into starvation:

  1. orderReviewFixKicksFirst puts a fix kick ahead of the governor kick for the same agent (πŸ› fix: keep review hold release across base-branch merges that do not change the PR diffΒ #13100).
  2. dispatchAgentKicks marks the lane busy after a delivered kick, so the governor kick behind it is agent busy: deferring kick β€” not failed, not counted, and re-rendered with no age next cycle.
  3. dispatchFix re-plans a fix kick for an adopted PR under changes_requested every cycle (πŸ› Keep adopted changes-requested PRs in the fixer work listΒ #12987), so there is always a fresh fix kick to displace the governor kick (✨ feat(hub): surface "Pause hive" in the hub spoke dropdown menuΒ #15105 was fix-kicked at 18:54, 19:19, 19:25).

Fix

kickLaneFairness (cmd/hive/review_kick_order.go) remembers per agent how many consecutive cycles the governor kick was assembled but deferred behind a delivered fix kick. At governorKickDisplacementLimit (2) the governor kick goes first for that cycle and the fix kick keeps its place after it β€” it is re-planned next cycle exactly as an undelivered fix kick is today. A delivered governor kick resets the count; cycles with no governor kick for the agent, or where the send failed outright, do not count. A WARN line names the agent and the streak when the override fires.

The governor kick already carries the agent's own red/conflicted PRs (FIX-BEFORE-NEW), so fix work is reordered, not lost.

Validation

… backlog kick

A review-fix kick is ordered ahead of the governor kick for the same agent
(#13100) and a delivered kick leaves the lane busy, so the governor kick
behind it is deferred β€” not failed, with no memory of the deferral. An
adopted contributor PR under changes_requested is re-planned as a fix kick
every cycle, so on the hosted spoke the scanner received 50 fix kicks and
no backlog kick for over an hour while 13 issues sat at
stage/010-actionable unclaimed.

Remember, per agent, how many cycles in a row the governor kick was
displaced by a delivered fix kick; after two the governor kick goes first
for that cycle and the fix kick is re-planned, exactly as an undelivered
fix kick is today.

Fixes #15166

Signed-off-by: Andrew Anderson <andy@clubanderson.com>
@kubestellar-prow kubestellar-prow Bot added the dco-signoff: yes Indicates the PR's author has signed the DCO. label Oct 28, 2026
@kubestellar-prow

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign danathar for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kubestellar-prow kubestellar-prow Bot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Oct 28, 2026
@github-actions

github-actions Bot commented Oct 28, 2026 •

Copy link
Copy Markdown
Contributor

Open PR overlap check

Base branch: v5

Conflicts are checked with every PR merged onto the current tip of v5, so a PR that only needs a rebase is not reported as conflicting with its siblings.

PR Title Relation Files
#15085 ✨ Activity Monitor: Adopt now and Reroute to another clanker for PRs waiting on a contributor's clanker same files src/cmd/hive/main.go
#15149 ✨ feat(automerge): pick one merge-train front per group of file-overlapping approved PRs same files src/cmd/hive/main.go
#15157 ✨ Conflict-aware merge train in the automerge lanes same files src/cmd/hive/main.go
#15105 ✨ feat(hub): surface "Pause hive" in the hub spoke dropdown menu same files src/cmd/hive/main.go
#15122 πŸ› Write-back containment: per-kind gate for every unsolicited GitHub write, with backfill guard same files src/cmd/hive/main.go

@hivecommons-hive

Copy link
Copy Markdown
Contributor

@clubanderson is auto-promoted for contributor-lane merging on this PR: the last 5 merged PRs by this author in this hive's repositories have no revert or sentinel-alert evidence. CI, reviewer verdict, diff fences, soak, holds and branch protection still apply.

@hivecommons-hive hivecommons-hive Bot added author/human A person pushed this PR themselves dco All commits are DCO signed-off role/trusted Author is trusted for unattended merge (trusted-author role or registry/claim tier in require_tiers) stage/050-review-pending Review swarm requested; awaiting a verdict for the current head labels Oct 28, 2026
@hivecommons-hive
hivecommons-hive Bot merged commit 73cdc6d into v5 Oct 28, 2026
79 of 82 checks passed
@kubestellar-prow
kubestellar-prow Bot deleted the fix/scanner-backlog-starved branch October 28, 2026 23:47
@github-actions

Copy link
Copy Markdown
Contributor

Thank you for your contribution! Your PR has been merged.

We'd love to hear how your experience was: share feedback

@hivecommons-hive

Copy link
Copy Markdown
Contributor
Evidence bundle `#151687d833a4` sha256:1e2ef1c61d41a3d07931bfb626d8b173156885cbb1092c595afe7357d4d066ab β€” download from the dashboard or `hivectl review evidence #15168`.

@hivecommons-hive

Copy link
Copy Markdown
Contributor

merged by Hive trusted-author auto-merge: author @clubanderson holds role owner and GitHub permission admin on repo; CI green at 7d833a4.

@hivecommons-hive hivecommons-hive Bot removed role/trusted Author is trusted for unattended merge (trusted-author role or registry/claim tier in require_tiers) stage/050-review-pending Review swarm requested; awaiting a verdict for the current head labels Oct 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

author/human A person pushed this PR themselves dco All commits are DCO signed-off dco-signoff: yes Indicates the PR's author has signed the DCO. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

πŸ› scanner backlog starved: review-fix kicks defer the governor kick every cycle

1 participant