Repository navigation
π Activity Monitor: exactly one lit stage chevron per row - #17337
Conversation
After a push during review the row lit CI and Review amber together (client lit each track independently; the chevron rules allowed the CI+Review pair). Derive one lead track (CI before Review); the other is dim with a muted queued note, its words in the tooltip. Reword the base-refresh detail line in operator terms (no preparation/unverified jargon, each signal once) and rename the handled-regression pill to "stage reset" / "stage reset by push". Doc rule: exactly one lit stage per row; later stages shown dim with a queued note. Fixes #17335 Signed-off-by: Andrew Anderson <andy@clubanderson.com>
|
/lgtm |
|
/approve |
|
@clubanderson: you cannot LGTM your own PR. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: clubanderson The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Open PR overlap checkBase branch: Conflicts are checked with every PR merged onto the current tip of No conflicting open PRs or same-file overlaps were found. |
|
Hive status β updated in place; edits do not notify. Full history is in the Activity Monitor. @clubanderson this PR is held at Failing checks:
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. Reviewed by Reviewer notesRead the full What I verified:
No findings. CI shows the build/merge jobs as skipped on this head; the required checks will need a run before tide moves it. |
Signed-off-by: Andrew Anderson <andy@clubanderson.com>
There was a problem hiding this comment.
Read the change against the tree at 2fd05e6 (merge-base with v5), not just the diff. Looks correct to me; no defects found.
What I verified
tracker-row-strip.js:stageTrackerLeadTrackand thewouldLightcomputation insidestageTrackerActivityTrackHtmluse the same inputs (stageTrackerTrackRunning,stageTrackerStageTrack,stalledTrack) and the samecurrent(sg.state === 'active'on the column-50 segment, which is whatstageTrackerStripItemspasses ascol50.state === 'active'), so the lead chosen instageTrackerStripItemscannot disagree with what each track thinks it would do.stalledTrackis only non-empty whentracksRunning === 0, so lead/stalled can't both light. Theopts.leadfallback (wouldLight ? kind : '') keeps the function self-consistent when harnesses call it alone.- Payload fields the new code reads exist on the server side:
push.state/push.sha(stage_tracker_push.go:42-49),code_activity.state === "pushed"(stage_tracker_activity.go:890),regressed_reason(stage_tracker.go:455). stage_tracker_ui_prelude_test.gotightens the fixture-wide invariant from β€2 to β€1 lit chevron and adds the dim-with-note / never-note-on-active assertions, so the behaviour change is pinned by a test that fails without it.- Merge order with the sibling Activity Monitor PRs:
git merge-treeof #17333 and #17334 onto this head both produce clean trees β the sharedtracker.css/activity-monitor.mdedits don't conflict textually.
Minor, not a defect: stageTrackerQueuedTrackNote's 'CI queued' branch is unreachable today, since stageTrackerLeadTrack always prefers CI when it would light; harmless.
β hive: agent=reviewer-2 backend=copilot model=claude-fable-5.1 copilot=1.0.88
There was a problem hiding this comment.
Read the render path on v5 rather than just the diff. The one-lead rule is wired consistently: stageTrackerStripItems computes leadTrack from col50.state === 'active' and the same stalledTrack it already passed as opts.stalled, and stageTrackerActivityTrackHtml derives current from sg.state === 'active' (tracker-row-strip.js:303), so stageTrackerTrackWouldLight and the per-track wouldLight = running || stageTrack || stalled evaluate the same predicate on the same inputs β the lead can't disagree with the track it demotes. stalledTrack is only non-empty when tracksRunning === 0, so the CI-vs-Review collision is always running vs stageTrack/adjudicating, and ['ci','review'].find picks CI as the body says. The opts.lead fallback (lead = wouldLight ? kind : '') keeps the harnesses that lift the function alone on the old behaviour.
The #16484 screenshot test and the running loop in stage_tracker_activity.test.js both flip from "two lit" to "CI leads, Review ham-track-queued", so the behaviour change is pinned by tests that fail without it.
Looks correct to me.
One scheduling note for whoever lands these: #17333 also edits src/pkg/dashboard/static/index.html, static-src/css/tracker.css and src/docs/dashboard-sections/activity-monitor.md, so the second of the two to merge will need a rebase (and a bundle regen) β not a defect in either, just avoid the stale-bundle conflict.
β hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88
|
Thank you for your contribution! Your PR has been merged. We'd love to hear how your experience was: share feedback |
|
merged by Hive trusted-author auto-merge: author @clubanderson holds role owner and GitHub permission admin on repo; CI green at 671f7ac. |
There was a problem hiding this comment.
Read tracker-row-strip.js on this head against the callers; the one-lit-track logic looks correct to me.
stageTrackerTrackWouldLight(row-strip, new) and thewouldLight = running || stageTrack || stalledexpression insidestageTrackerActivityTrackHtmluse the same three conditions with the samecurrent(sg.state === 'active'on column 50 in both call sites), andstalledTrackis only non-empty whentracksRunning === 0, so the lead chosen instageTrackerStripHtmlcan never disagree with the per-trackwouldLightβ no row can end up with zero lit chevrons when one would have lit before.['ci','review'].find(...)means CI always wins when both would light, so thekind === 'ci'branch ofstageTrackerQueuedTrackNoteis unreachable in practice; harmless, just dead.- The
leadfallback (opts.lead || (wouldLight ? kind : '')) keeps the harnesses that liftstageTrackerActivityTrackHtmlalone on their old behaviour. stage_tracker_activity.test.jsflips the #16484/#16599 assertions fromactivetotodo ham-track-queued+review queued behind CI, so the tests fail without the change.
All checks green except mobile-shots (still running) and tide. Nothing blocking from my side; not approving, since the PR already carries approved.
β hive: agent=reviewer-2 backend=copilot model=claude-fable-5.1 copilot=1.0.88
Fixes #17335
Root cause
stageTrackerActivityTrackHtmllit each track independently (lit = running || stageTrack || stalled) and the chevron rules (#16599/#16643) permitted CI + Review as an active pair. At stage 050 right after a push, CI isrunningand Review is the stage's own track with an unsettled verdict (adjudicating) β both amber. The server legitimately carries both sub-states; the client never chose a lead. Fixed client-side at the render.Changes
stageTrackerLeadTrackpicks the earliest track that would light (CI before Review); the other rendersham-track-queued(dim, no pulse) with a muted note: re-review queued after a push, review in progress, review queued; its words move to the tooltip (β¦ behind CI). Prelude invariant tightened from β€ 2 to β€ 1 lit.tracker-preparation.js: "New push c15a343 by @Karibhou 3m ago β CI running, review will rerun Β· previous review no longer applies Β· Recorded first for the base refresh Β· ticket issued for an earlier head Β· re-checked on c15a343 Β· ticket issued 4m ago". No preparation / unverified / ticket age; serverDetailstrings unchanged (data), mapped at render. Queue chip reworded likewise.stage βpill β it is the hive-handled regression marker; now reads stage reset, or stage reset by push whenpush.state === 'pushed'or the reason names a push. Tooltip unchanged.stage βmentions updated;index.htmlregenerated.Tests
stage_tracker_ui_rows_test.go: π± test: regression for an epic-driven PR on a contributor-claimed, PR-covered issueΒ #17308 push-during-review fixture β 1 lit (CI), Review dim + re-review queued;both/busyfixtures β 1 lit.stage_tracker_preparation_visual.test.js: push fixture detail string equals the plain sentence and matches no/preparation|unverified|ticket age|Head changed/i.stage_tracker_regressed_test.go: pushed / reason-named cases render stage reset by push; nostage β.stage_tracker_activity.test.jswired to the new helpers; expectations updated.