Repository navigation
docs(sidebar): describe the first-load pinned-order seed accurately - #22936
mbriones98 wants to merge 2 commits into
Conversation
UX Review (Opus 5.5) — ✅ PASSUX-level review of UX-Verdict: PASS Nothing to check. The diff only changes comments and docstrings, so users see nothing new or different. That's why having no blind read and no screenshot leaves nothing unreviewed. [UX-REVIEWED] 2a53403 Description read[DESCRIPTION-READ] 8dbf885933eb9d40e09f512777d3d12c70d6be1dc2181dfaea4647e40ba84490 That sha256 names everything this verdict read: the PR description, plus the 3 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with |
Design Review (Opus 5.5) — ✅ PASSDesign-level review of Design-Verdict: PASS Only comments change, and the new text matches the code: [DESIGN-REVIEWED] 2a53403 Description read[DESCRIPTION-READ] b4286bea86a37d0a6b1042d1c1eadad789e76ed575d36c8d529be1d5ca251a43 That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with |
First Principles Review (Opus 5.5) — ✅ PASSPremise-level review of First-Principles-Verdict: PASS Comments only, and each edit matches code that already exists: the What this change shipsInventory (5 items) — 5 justifiedIntent: make the comments that state the pinned-order rules match what the sidebar does on first load (#22182). This is a FIX.
[FIRST-PRINCIPLES-REVIEWED] 2a53403 Description read[DESCRIPTION-READ] c9c6cc5d42533d6e841d75f2f33f116d64ea81fd020ade649d07dd50f1917fa4 That sha256 names the PR description this verdict read. Recompute it with |
Opus 5.5 Review — ✅ no blocking findingsReviewed Verdict parsed from the review's SHA-scoped output markers for commit False positive or not applicable? A repository writer can comment: |
GPT 6.1 Review — ✅ no blocking findingsGPT 6.1 completed its review of This comment is updated in place on each push. Review detailsNo findings. False positive or not applicable? A repository writer can comment: |
The pinned-order contract said pinned rows stay unranked until someone reorders. The sidebar's first list-view load seeds the order it shows, so rows gain a rank without a reorder. Say so, and list the cases where rows do stay unranked. Align the only_if_unset note on the gateway side. Fixes #22182
Say that rows stay unranked until the seed succeeds, that a failed seed waits for the next page load, and that a refused seed takes the stored order. Note that a board view with an old local order also seeds, and drop the remaining 'never reordered keeps the plain sort' lines.
6a01a17 to
2a53403
Compare
iamwhatever
left a comment
There was a problem hiding this comment.
Requesting changes for one tracking item only; the edits themselves are correct.
Reviewed head: 2a53403
The new comments match the code. usePinnedOrderAuthority seeds the old local order plus the natural order with only_if_unset, skips a board view only when no local order exists, waits on an empty roster, does not retry a failed seed until reload, and takes the stored order after a 409. The new contract text lists exactly those cases. CI and all AI lanes are green.
What needs a change: the description's Not a goal says changing the seed itself (seeding only when a browser kept an old local order, option 2 in #22182) is "left to a separate issue", but no issue is linked, and Fixes #22182 closes the only place that question is written down. Please either open an issue for that behaviour question and link it in the description, or, if option 2 is rejected rather than deferred, say so in Not a goal instead of promising a separate issue.
— crew-pr-reviewer (r130)
|
[operator: bolichen97] Continuing this in #31411; thanks for the start. |
The pinned-order contract said a person who never reordered keeps the plain sort inside the pinned section. The sidebar's first list-view load seeds an order with only_if_unset (this browser's old local order if it kept one, then the natural order), so rows gain a pin_rank without any reorder and later pins append. The seed is intended, so the text is corrected wherever it repeated the claim: the contract docstring, the seed hook and client notes, the route and store docstrings, the agent-facing pin-move description and session-control doc, and the owning spec. No code changes. Builds on #22936. Co-authored-by: Matthew Briones <50031759+mbriones98@users.noreply.github.com>
The pinned-order contract said a person who never reordered keeps the plain sort inside the pinned section. The sidebar's first list-view load seeds an order with only_if_unset (this browser's old local order if it kept one, then the natural order), so rows gain a pin_rank without any reorder and later pins append. The seed is intended, so the text is corrected wherever it repeated the claim: the contract docstring, the seed hook and client notes, the route and store docstrings, the agent-facing pin-move description and session-control doc, and the owning spec. No code changes. Builds on #22936. Co-authored-by: Matthew Briones <50031759+mbriones98@users.noreply.github.com>
The pinned-order contract said a person who never reordered keeps the plain sort inside the pinned section. The sidebar's first list-view load seeds an order with only_if_unset (this browser's old local order if it kept one, then the natural order), so rows gain a pin_rank without any reorder and later pins append. The seed is intended, so the text is corrected wherever it repeated the claim: the contract docstring, the seed hook and client notes, the route and store docstrings, the agent-facing pin-move description and session-control doc, and the owning spec. No code changes. Builds on #22936. Co-authored-by: Matthew Briones <50031759+mbriones98@users.noreply.github.com>
Pull request was closed
Problem / Motivation
Goal: Make the pinned-order contract text describe what the sidebar actually does on first load.
The docstring in
website/src/utils/pinnedSessionOrder.tssays pinned rows stay unranked until someone reorders, so the pinned section keeps its plain sort. In the list view that is not what happens: the sidebar's first load saves the order it is showing (only_if_unset), so every pinned row gets apin_rankwithout anyone reordering, and a later pin appends instead of sorting in. Several other comments repeat the same claim.Why it matters
The docstring reads as the contract for pinned ordering. Anyone changing the sidebar or the gateway route from that text would expect unranked rows that are in fact ranked, and could "fix" the intended seed or build on behaviour that does not exist.
Not a goal
handOff/legacyPinnedOrderMigratedidentifiers.What changed (motivation → approach → change)
Symptom: the contract text promises a plain sort the sidebar does not keep. Cause: the first-load seed is deliberate (its own comment says so, and
ChatSidebar.hapticTaps/ChatSidebar.slotSearchOrdertests name it), so the text is what is wrong. Change, comments and docstrings only:website/src/utils/pinnedSessionOrder.ts: describe the first-load seed, and list when pinned rows do stay unranked: a board view with no old local order, an empty roster, before the seed succeeds, after a failed seed until the next page load, and a refused seed taking the stored order from the next slots frame.website/src/pages/chat-sidebar/pinnedOrder.ts: align theusePinnedSessionOrdercomment, and correct theusePinnedOrderAuthoritynote (a board view with an old local order does seed).src/kiro_crew/dashboard/chat_folders.py: theonly_if_unsetnote now says the first-load seed uses it, including for a browser that never kept a local order.src/kiro_crew/dashboard/pinned_session_order.py: replace the "never reordered keeps the plain sort" lines with "no saved order".Backwards compatibility
Compatible: only comments and docstrings change; no code path, route, or stored format is touched.
Removes nothing: the diff edits text in comments and docstrings only.
Tests
No tests added (no behaviour change). Ran:
pytest test/test_pinned_session_order.py test/test_pinned_order_real_sandbox.py: 132 passed, 6 skippedvitest run src/test/ChatSidebar.hapticTaps.test.tsx src/test/ChatSidebar.slotSearchOrder.test.tsx: 17 passedtsc --noEmit; eslint on the two touched TS files; black, flake8 and isort on the two touched Python filesscripts/check_file_line_cap.pyandscripts/docs_lint.py: passManual verification
N/A — docs/comments only, no runtime behaviour to exercise.
Screenshots / video
Why no screenshot: docs/comments only, no UI change; the only edit under
website/src/pages/is a code comment.Related Issues
Fixes #22182
Follow-up: #25075 (deferred seed change, option 2 in #22182)
Replaces #22919 (reopened from a repo branch)
Pattern harvest
Not generalizable: the drift came from one deliberate seed path widening a narrow "until someone reorders" sentence, which no lint or rule could tell apart from intended prose.
Checklist
feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)Contribution License Agreement
Contributions are accepted under the project's Apache-2.0 license; see the Licensing section of CONTRIBUTING.md.