Skip to content

๐Ÿ› tracker: a PR waiting on its author never leads with Close as superseded - #15664

Merged
clubanderson merged 5 commits into
v5from
fix/no-destructive-lead-chip
Oct 30, 2026
Merged

clubanderson merged 5 commits into
v5from
fix/no-destructive-lead-chip

Conversation

@clubanderson

Copy link
Copy Markdown
Member

Fixes #15663

Why

What

  • StageTrackerDecisionOption gains Lead bool (json:"lead"); the server sets it only in decisionLeadWithCloseSuperseded (the reviewer's RedundantOf), the one place a close is the answer.
  • stageTrackerLeadActions never flags a danger (decide:close-*) option as the row's lead unless o.lead; the Decideโ€ฆ fallback in stageTrackerLeadAction skips danger entries. The โ‹ฏ menu is unchanged.
  • decisionForWaitingOnAuthor no longer asks "Wait for them, or close it?"; the waiting pill for a person's own PR reads "waiting on @author to push".
  • New stageTrackerLeadActionOnRow: an issue row whose lead acts on a nested PR drawn as a sub-row renders no button โ€” the sub-row (with the chevron) carries it; the parent keeps "Decide PR #Nโ€ฆ" in โ‹ฏ.
  • static/index.html regenerated with make dashboard-gen.

Tests

  • stage_tracker_row_actions_test.go: waiting-on-author โ†’ no close lead / no inline button; the live 085 sent-back shape โ†’ non-destructive lead, close still in โ‹ฏ; lead: true redundant-of โ†’ Close as superseded still leads.
  • stage_tracker_decision_redundant_test.go: Lead set on the RedundantOf path only; TestDecisionForWaitingOnAuthorNeverLeadsWithClose.
  • stage_tracker_lead_action_test.go: a parent + nested-PR pair yields exactly one lead button.
  • Presence tests updated for "to push".

โ€ฆseded

A human-authored PR the review swarm sent back for changes rendered the
red inline 'Close as superseded' button: stageTrackerLeadActions flagged
every server decide:* option not already in the Decideโ€ฆ submenu as lead,
and once delegate/hold were taken the first leftover was the close.

- StageTrackerDecisionOption gains Lead (json lead); the server sets it
  only where a close is the answer (decisionLeadWithCloseSuperseded, the
  reviewer's RedundantOf).
- The SPA never leads a row with a danger option unless o.lead, and the
  Decideโ€ฆ fallback skips danger entries; the โ‹ฏ menu is unchanged.
- The waiting pill for a person's own PR reads 'waiting on @x to push'
  and the popover question no longer asks 'or close it?'.
- Tests updated; focused cases for waiting-on-author (no close lead),
  the live 085 sent-back shape, and redundant-of (close still leads).

Signed-off-by: Andrew Anderson <andy@clubanderson.com>
โ€ฆsted PR

An issue with several linked PRs draws a sub-row per PR; when one parked
PR asks, stageTrackerDecisionTarget resolved the issue row's lead to that
PR as well, so the same 'Let hive decide' button appeared on the parent
header and on the sub-row (hive#15320 โ†’ #15647, hive#15338 โ†’ #15648).

stageTrackerLeadActionOnRow drops the parent's lead when it acts on a
nested PR that is drawn as a sub-row and renders its own; the parent's โ‹ฏ
menu keeps 'Decide PR #Nโ€ฆ'. Test: a parent + nested-PR pair yields one
button.

Signed-off-by: Andrew Anderson <andy@clubanderson.com>
Signed-off-by: Andrew Anderson <andy@clubanderson.com>
@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 nicholasjackson 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 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. labels Oct 30, 2026
@github-actions

github-actions Bot commented Oct 30, 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
#15637 ๐Ÿ“– community: list the Twitch live stream everywhere community links live same files src/pkg/dashboard/static/index.html
#15657 ๐Ÿ› Tracker: chevron column follows the current state, never the highest stage reached same files src/pkg/dashboard/static-src/js/tracker-row.js
src/pkg/dashboard/static/index.html
#15669 โœจ Stream the tracker's sounds on the Activity Monitor Twitch stream same files src/pkg/dashboard/static/index.html
#15662 ๐Ÿ› Adopt stuck contributor PRs automatically from the tracker's offer predicate same files src/pkg/dashboard/stage_tracker_presence_test.go
#15566 ๐ŸŒฑ refactor: split stage tracker UI tests same files src/pkg/dashboard/static/index.html
#15530 ๐Ÿ› fix(dashboard): issue-row linked PR passes null when the lineage chip is empty same files src/pkg/dashboard/static-src/js/tracker-row.js
src/pkg/dashboard/static/index.html
#15633 ๐ŸŒฑ refactor: split stage tracker UI tests same files src/pkg/dashboard/static/index.html
#15680 ๐Ÿ› review: one backlog issue per finding; carried-over notes never refile same files src/pkg/dashboard/static/index.html
#15658 ๐Ÿ› fix(tracker): PRs at CI / Review ride no merge train; overlap hint instead same files src/pkg/dashboard/static-src/js/tracker-row.js
src/pkg/dashboard/static/index.html
#15668 ๐Ÿ› Lead 090 merge-gate action is Approve and let hive merge same files src/pkg/dashboard/stage_tracker_decision.go
src/pkg/dashboard/stage_tracker_row_actions_test.go
src/pkg/dashboard/static-src/js/tracker-actions.js
src/pkg/dashboard/static-src/js/tracker-row.js
src/pkg/dashboard/static/index.html
#15521 ๐ŸŒฑ refactor: split tracker row source CONFLICT src/pkg/dashboard/static-src/js/tracker-row.js

@hivecommons-hive

Copy link
Copy Markdown
Contributor

@clubanderson this PR is held at stage/071-needs-author and the hive will not merge it yet.

Failing checks:

  • coverage

Next: the hive does not push to your branch. Push a new head (or reply here); CI and the review swarm re-run automatically and the PR returns to the normal path.

@hivecommons-hive

Copy link
Copy Markdown
Contributor

stage 080-awaiting-merge-admission โ†’ 071-needs-author: required-check-failing:coverage

โ€ฆubmenu lists its verb

Signed-off-by: Andrew Anderson <andy@clubanderson.com>
@hivecommons-hive

Copy link
Copy Markdown
Contributor

stage 080-awaiting-merge-admission โ†’ 050-review-pending: required-check-pending:Sign-off survives the squash

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Read tracker-actions.js:355-470, tracker-row.js:1043-1350, stage_tracker_decision.go:555-900 and the generated index.html at c8bc8fa. Looks correct to me.

  • The lead rule is now explicit in one place: lead: !danger || !!o.lead (tracker-actions.js:373) plus the submenu fallback filtering !x.danger (:445). The only producer of Lead: true is decisionLeadWithCloseSuperseded (stage_tracker_decision.go:894), i.e. RedundantOf set, so a close can lead only when a reviewer named the superseding PR. The Go test asserts no other option is ever marked lead.
  • I checked the taken && โ€ฆ && !o.lead bypass (:364): in the redundant-of case the โ‹ฏ menu gets the prefilled "Close as superseded" at top level while Decideโ€ฆ keeps the generic "Close as superseded byโ€ฆ" (stageTrackerDecideOptions). The inline comment says that's intended; noting it so nobody reads it as a dup later.
  • stageTrackerLeadActionOnRow (:472-481) only suppresses the parent button when item.kind === 'issue', sub-rows are actually drawn (subRows is set only on the linked.length > 1 branch, tracker-row.js:1304), the target is one of them, and that sub-row itself yields a lead โ€” so the single-linked-PR case and an issue's own 045 ask keep their button. Both pinned in the node fixture.
  • static/index.html is regenerated in the diff and matches static-src for the three touched functions.

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

@clubanderson
clubanderson merged commit d086be1 into v5 Oct 30, 2026
77 checks passed
@kubestellar-prow
kubestellar-prow Bot deleted the fix/no-destructive-lead-chip branch October 30, 2026 04:41
@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 Bot added a commit to Karibhou/hive that referenced this pull request Oct 30, 2026
Port the v5 tracker-row.js changes (hivecommons#15657, hivecommons#15664, hivecommons#15668, hivecommons#15680) into
the split files: stageTrackerAnchor under-repair column (tracker-row.js),
acted labels (tracker-row-strip.js), queue-merge pending copy
(tracker-row-acted.js), and stageTrackerLead / left_train / subRows /
review notes (tracker-row-layout.js). static/index.html regenerated and
matches the auto-merge byte for byte.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Signed-off-by: scanner <280983584+hivecommons-hive[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

conflicts-with-open-pr Open PR has a merge conflict with another open PR 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.

๐Ÿ› tracker: a PR waiting on its author leads with Close as superseded; Let hive decide renders twice per issue

1 participant