Skip to content

πŸ› fix: preserve supersession decisions across stage reconciliation - #14979

Merged
hivecommons-hive[bot] merged 4 commits into
v5from
hive/adopt-14821
Oct 28, 2026
Merged

hivecommons-hive[bot] merged 4 commits into
v5from
hive/adopt-14821

Conversation

@hivecommons-hive

Copy link
Copy Markdown
Contributor

Supersedes #14821 (adopted after CI went red and the contributor was unavailable; original commits by @thatguywob preserved).

Fixes #14814

This branch is #14821's head beb4233d8f4b as pushed by @thatguywob (fork thatguywob/hive), unchanged. Last lane reason on the original: contributor-lane:decision-requested.

Hive fix agent: rebase this branch on v5, fix the failing checks / review asks, and push to THIS branch. Keep the original author's commits and their Signed-off-by; add your own sign-off on your commits. Do not open another PR.

thatguywob and others added 3 commits October 28, 2026 03:51
Keep a supersession cause label separate from CI and author repair state,
retain escalation evidence in tracker audit replay, and expose the closer
and keep-open reason even when a stale record still says 071/072.

Allow trusted maintainer decisions to close superseded contributor PRs
without a branch push. Detect held duplicates without writes, allow
ancillary file differences only with implementation overlap, and skip
closed contributor queue snapshots.

Hive-Run: #14814
Hive-Plan: issue-14814-supersession-sweep-and-stage-tracker
Hive-Spec: issue-14814#fleet-generic-fix
Co-authored-by: clubanderson <407614+clubanderson@users.noreply.github.com>
Signed-off-by: thatguywob <thatguywob@users.noreply.github.com>
Persist supersession park labels in the dashboard sweep fixture and assert the second pass makes no additional writes. Preserve slash-containing label names in the GitHub fixture so reopened-issue cleanup is observed.

Signed-off-by: thatguywob <thatguywob@users.noreply.github.com>
…e reject routable

TestReviewQueue_SweepDetectionWithoutAutoClose built its client without a
stage fact sink, so the new escalation path re-read the PR through the live
reconciler and hit the fixture's 404 (dashboard shards 4/4 and shuffle 3/3).
Install the recording sink the pkg/github sweep tests use and assert the
Parked fact.

A bare `/hive decision reject` on a PR nothing supersedes now continues to
the changes-requested path instead of being answered with "stays open";
only the explicit `close superseded by #N` form is always answered by the
supersession handler. Covered by a sweep-level regression test and the
maintainer-commands doc.

Hive-Fix-Attempt: 1/6

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Signed-off-by: ci-maintainer <280983584+hivecommons-hive[bot]@users.noreply.github.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 kubestellar-prow Bot added the size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. 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 kellyaa 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

@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
#14524 ✨ feat(hub,agent): Hub-coordinated live CLI session pool for multi-tenant runner capacity same files src/cmd/hive/main.go
#14821 πŸ› fix: preserve supersession decisions across stage reconciliation same files changelog.d/fixed-14814-supersession-stage.md
src/cmd/hive/main.go
src/docs/maintainer-commands.md
src/pkg/dashboard/api_review_queue_superseded.go
src/pkg/dashboard/api_review_queue_superseded_test.go
src/pkg/dashboard/stage_tracker.go
src/pkg/dashboard/stage_tracker_supersession_test.go
src/pkg/dashboard/static/index.html
src/pkg/dashboard/worksource_identity.go
src/pkg/github/automerge/automerge_stage_labels.go
src/pkg/github/automerge/automerge_stage_supersession_test.go
src/pkg/github/pr_supersession_autoclose.go
src/pkg/github/pr_supersession_autoclose_test.go
src/pkg/github/pr_supersession_decision.go
src/pkg/github/pr_supersession_decision_test.go
src/pkg/github/pr_supersession_resolve.go
src/pkg/github/pr_supersession_resolve_test.go
src/pkg/github/pr_supersession_sweep.go
src/pkg/github/pr_supersession_sweep_test.go
src/pkg/github/pr_unpark_decision.go
src/pkg/github/review_queue.go
src/pkg/stageengine/derive_pr.go
src/pkg/stageengine/derive_pr_classify.go
src/pkg/stageengine/derive_pr_supersession_test.go
src/pkg/stageengine/prstage/reasons.go
#14987 ✨ review: gate PR reviews on an approval label (review.require_labels) same files src/cmd/hive/main.go
src/pkg/dashboard/static/index.html
#14822 πŸ› fix: preserve owner intent through PR decision paths same files src/docs/maintainer-commands.md
src/pkg/github/pr_unpark_decision.go
#14807 ✨ dashboard: stream Job pod logs in the terminal pane for sandbox.runtime: job agents same files src/pkg/dashboard/static/index.html
#14921 ✨ feature: inline the linked Linear issue into review kicks same files src/cmd/hive/main.go

@hivecommons-hive hivecommons-hive Bot added author/hive This repository's own hive (the App or one of its agent lanes) authored this PR 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 left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Decision needed: @clubanderson should decide whether #14821 (contributor fork branch, @thatguywob) or this hive adoption #14979 carries commit beb4233 for #14814 β€” both heads are the identical SHA, so the other should be closed.

Decision needed: @clubanderson should decide whether #14821 (contributor fork branch) or this hive adoption #14979 carries commit beb4233 for #14814 β€” the two heads are the same SHA and the other should be closed.

Facts I verified, not inferred:

  • hive-gh pr view shows headRefOid beb4233d8f4beddf313aa72671d4957368e6a58a on both #14821 and #14979, same base v5, same ten-file set (src/pkg/dashboard/stage_tracker.go, api_review_queue_superseded.go, automerge_stage_labels.go, …). This is not a "same files, different fix" pair β€” it is literally one commit under two PR numbers.
  • The open decision question on #14821 asks you to choose between it and adoption #14862 (head c47eff3, "tests red"). #14862 is now closed-unmerged, and this adoption re-uses #14821's head unchanged, so the "different fixes for bare /hive decision reject" conflict that question described no longer exists. That question can be considered answered by events; the only live question is the one above.
  • The adoption body says CI "went red" on #14821. At this head every check on both PRs is SUCCESS except build (linux/arm64…) still in progress and tide pending β€” identical on both. So neither PR is currently preferable on CI grounds.

Trade-off for the decision: #14821 keeps @thatguywob as PR author (DCO-signed commits are preserved either way); #14979 is a branch the hive fix agent can push to if a rebase is needed. I have not re-reviewed the code at this head β€” the review already recorded on #14821 at beb4233 applies to this PR verbatim. I have not closed anything.

β€” hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Decision needed: @clubanderson should decide whether to close contributor PR #14821 in favour of this hive adoption #14979 β€” both sit at the identical head beb4233 and cannot both merge β€” now that the earlier conflicting adoption #14862 has been closed.

Decision needed: @clubanderson should decide whether to close contributor PR #14821 in favour of this hive adoption #14979 β€” both sit at the identical head beb4233 and cannot both merge β€” now that the earlier conflicting adoption #14862 has been closed.

This PR and #14821 are the same bytes. headRefOid is beb4233d8f4beddf313aa72671d4957368e6a58a on both; this branch hive/adopt-14821 is, per its own body, #14821's head "unchanged". So this is not a conflict and not a divergence β€” it is one change under two numbers.

What changed since #14821 was parked at stage/085-needs-decision:

  • The question parked there was "this PR vs its adoption #14862 (head c47eff3), which carry different fixes for bare /hive decision reject". #14862 is now closed, unmerged (closed_at 2026-10-28T12:40:02Z), so that question is moot.
  • The adoption body says this was adopted "after CI went red". At this head, checks are 27/29 green with only build (linux/arm64, …) still in progress and tide pending β€” nothing red. I note it as a fact, not a complaint; it just means there is nothing for the fix agent to fix yet.

On the code itself I have nothing to add: head beb4233 was reviewed on #14821 by the adjudicator at this exact SHA with no correctness findings, and the only finding then was the #14862 divergence described above. Re-posting that review on the same bytes would be noise.

Recommendation, for a human to act on: keep one. This copy lives on a hive-owned branch (hive/adopt-14821) the fix agent can push to; #14821 is a fork branch the hive can only comment on. If you prefer the contributor's PR to carry the credit, the reverse works equally well β€” the diffs are identical. I have not closed anything.

β€” hive: agent=reviewer-2 backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive hivecommons-hive Bot added stage/085-needs-decision A human decision is owed: sentinel alert, hold/needs-decision label, human-only rule or parked issue and removed stage/050-review-pending Review swarm requested; awaiting a verdict for the current head labels Oct 28, 2026
@hivecommons-hive

Copy link
Copy Markdown
Contributor Author

Needs a decision, not a merge:

Head: verdict requires_human @beb4233, 67/68 checks green, 1 pending, DCO yes, soak 0s of 30m0s.

What to do: approve this head (beb4233) to merge as-is, or leave a changes requested review (or reply /hive decision <what to change>) and the hive will push the fix.

How to release it:

  • After reading the verdict, a trusted merger can submit a GitHub Approve review for the current head and the lane clears the hold on its next pass; /hive approve replies on a PR are acknowledged but not consumed.

Clear the cause and the hive re-evaluates on its next pass; the stage moves to stage/090-ready-for-human-merge, stage/095-pre-merge-soak or the merge queue on its own. Approval does not bypass CI, hold labels or other merge gates.

@hivecommons-hive

Copy link
Copy Markdown
Contributor Author

Supersession sweep found that this PR's claimed issue is already closed by another merged PR.

  • Claimed issue: hive#14814
  • Closing PR: #14823

This PR touches files the merged PR did not, so the hive is resolving it itself: updating head beb4233 onto v5 to measure what #14823 left for it to add. If nothing meaningful remains it will close; otherwise its claim becomes Refs and it continues in the lane.

This comment is edited in place by the supersession sweep; it is not duplicated.

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks correct to me, and this is the PR that should carry #14814 β€” #14821 can be closed in its favour once a maintainer agrees. I have not closed anything.

What this is. Head 3033244 is #14821's head beb4233 (commits 0d69dd4, 30a71c9, beb4233, author sign-offs intact) plus one merge of v5. I diffed both PRs against v5: the two diffs are identical apart from hunk offsets (cmd/hive/main.go, stage_tracker.go, automerge_stage_labels.go moved on v5). Same change, same intent; both cannot merge.

Why this one survives. The decision parked on #14821 was "this PR vs its adoption #14862, which carry different bare-reject fixes". #14862 is now closed, so that question is moot: this adoption carries #14821's own fix, not #14862's. It is on a hive-controlled branch, already rebased, and every check is green on this head (test (dashboard 1/4) and test (dashboard shuffle 3/3), the two that were red at 30a71c9, pass here). #14821 is a fork branch the hive cannot push to and is still sitting at stage/085-needs-decision on the stale question.

Correctness re-read at 3033244. The earlier low-severity finding on 30a71c9 β€” a non-superseded bare /hive decision reject on a hive-authored PR being swallowed β€” is fixed: src/pkg/github/pr_supersession_decision.go:40-56 returns handled=false when no live supersession is detected (or the PR is held) and the request was a bare reject, and src/pkg/github/pr_unpark_decision.go:70-80 only returns early when handled is true, so the request falls through to the existing selfAuthored changes-requested path. An explicit close superseded by #N still always gets a reply, including the closer-mismatch case (pr_supersession_decision.go:57-59). The rest of the design (085 cause label surviving CI/rebase/DCO reconciliation, trusted-merger gate at pr_unpark_decision.go:50-52, no contributor-branch push) is unchanged from the version already read on #14821.

β€” hive: agent=reviewer backend=copilot model=claude-fable-5.1

@hivecommons-hive
hivecommons-hive Bot merged commit e53882a into v5 Oct 28, 2026
81 of 83 checks passed
@kubestellar-prow
kubestellar-prow Bot deleted the hive/adopt-14821 branch October 28, 2026 16:27
@hivecommons-hive

Copy link
Copy Markdown
Contributor Author
Evidence bundle `#149793033244` sha256:25d4709db7dcec5422bb805d0ae112d74210c698d189e32f307e85a2db591feb β€” download from the dashboard or `hivectl review evidence #14979`.

@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

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

Labels

author/hive This repository's own hive (the App or one of its agent lanes) authored this PR copilot dco All commits are DCO signed-off dco-signoff: yes Indicates the PR's author has signed the DCO. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Supersession sweep flags duplicate PRs but stage tracker shows closed issue β†’ open PR with no superseded signal; 085 park is overwritten by 071/072

1 participant