Repository navigation
fix(capabilities): readable rows and fixes for four more chat-start refusals - #21914
Conversation
Design Review (Opus 5.5) — ✅ PASSDesign-level review of Design-Verdict: PASS Before merging, trigger one real refusal on a live crewmate and confirm the row names that member and the right project. The author says this was not done. [DESIGN-REVIEWED] 6396373 Description read[DESCRIPTION-READ] a63bbbb0c83deb1dfdee09d24ce63d7f59ab9c812305e820c398b46511f31bb0 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 Still unchecked: no live refusal has been triggered on a real crewmate to confirm the row names that member and the right file and project; the author says they skipped this. Not justified as shipped
What this change shipsInventory (8 items) — 7 justifiedIntent: when a crewmate's chat can't start for one of four capability reasons, the user sees why and gets a fix that works instead of a Resume that fails again. FIX (Closes #14005).
[FIRST-PRINCIPLES-REVIEWED] 6396373 Description read[DESCRIPTION-READ] 0d57901ee86523351577337174007d1db72e92bb8e1f0ba5a0722154a3621864 That sha256 names the PR description this verdict read. Recompute it with |
UX Review (Opus 5.5) — 🟡 CONCERNSUX-level review of UX-Verdict: CONCERNS The two rows with no button stop at an instruction the user can't carry out in the app, and the screenshot of the shadowed-file row shows copy that no longer ships. Watch
Suggestions
[UX-REVIEWED] 6396373 Description read[DESCRIPTION-READ] 8be33ee9f9fd29ac6a56a92bc52d554048024cefebf984779239196ad9063492 That sha256 names everything this verdict read: the PR description, plus the 9 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 |
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: |
3666c19 to
d8c88b8
Compare
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
0cf935c to
6396373
Compare
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Review-ready at 6396373: PR Readiness passed (113 checks, 0 failing), GPT and Opus lanes have no open findings, and every Design / First Principles / UX item has a disposition. Waiting on a maintainer review. Two things for the reviewer: (1) one live refusal on a real crewmate is still unchecked (see Manual verification); (2) the UX lane keeps re-raising wording points across rounds (crewmate name in 'Open ', reason-first vs action-first in the shadowed-file row, a project-switch control); I stopped changing copy and left those rulings to you. This worker will not merge, approve or enable auto-merge. |
chenmingwei23
left a comment
There was a problem hiding this comment.
Approving per maintainer bulk readiness pass (readiness: passed, no failing lanes).
Problem / Motivation
Goal: When a crew member's chat cannot start for one of four capability reasons, the chat row says why in plain words and offers the fix that works, instead of a bare code and a Resume that fails again.
prepare_member_capabilitiesrefuses a chat start withparent_identity_changed,foreign_private_copy,project_identity_changedorprivate_template_shadowed. Today the chat shows the bare code and a Resume button. Resume runs the same check and fails the same way, so the user is stuck. PR #13523 fixed this formaterialization_changedonly.Why it matters
A user whose crewmate hits one of these refusals has no way out from the chat. Pressing Resume repeats the failure, and the code does not say what to do.
Not a goal
prepare_member_capabilitiesrefuses a start.KiroCrewAgentsPage.tsx, so this PR does not touch that page.materialization_pendingandgovernance_reconciliation_pending, which the start's own reconcile step can clear.What changed (motivation → approach → change)
Each code needs its own fix, so the row now picks copy and a button per code:
parent_identity_changedforeign_private_copyproject_identity_changedprivate_template_shadowed.kiro/agents(the copy leads with this step)None of these rows offers Resume, and while one is the newest row the composer's Resume yields too (
newestErrorOwnsRecovery), which now also coversmaterialization_changed. The two codes with no button have no in-app fix, so the copy names the step. The backend writes an English row with the code and member, plus the shadowing file's real basename and the project whose.kiro/agentsholds it for the shadowed case (set on both raise sites, includingCapabilityService._snapshot) and the saved project forproject_identity_changed(newCapabilityError.project). When no project was saved, the row says "another project" instead (capabilities_project_changed_other). A foreign-copy row with no member usescapabilities_foreign_copy_unnamedand shows no button. The dashboard shows its own localized copy in all 12 languages: newpages.chat.errorCardkeys inwebsite/src/i18n/locales/(en.manual.jsonplus each locale file;en-XA.jsonregenerated bynpm run i18n:pseudo).agent_not_found(the member is gone from config, a 404) stays as it is: it is not one of the four codes this issue tracks, and its fix is not a capability one.Where it lives: the code-to-copy-and-fix table is in
website/src/pages/chat/ErrorCard.tsx.website/src/pages/chat/transcriptRenderers.tsxwithholds Continue and passes the fix along.website/src/pages/chat/page/turnRecovery.tsopens either the Capabilities pane or the crewmate editor, andwebsite/src/pages/chat/page/transcriptRendering.tsxcarries the new callback type. The English row text is insrc/kiro_crew/dashboard/chat_runner.py.src/kiro_crew/agent_capabilities.pyadds the file and project to the refusals. BecauseCapabilityService._snapshotnow setsfiletoo, the Capabilities pane's409 private_template_shadowedbody (handlers/agent_capabilities.py) also carries that basename, likeunreviewable_driftalready does.docs/system-specs/modules/crew-mode.mddocuments the four rows next to thematerialization_changedone.Backwards compatibility
Compatible: rows for other codes render as before, and
materialization_changedkeeps its copy and Open Customize button.Removes nothing: the change adds copy and buttons for four codes. No key, route or field is dropped.
Tests
test/test_chat_runner_coverage_turn_start.py::test_sibling_capability_refusals_name_their_own_fix(one case per code): the row starts with the code, names its fix, has no unfilled{}, and carriescode,memberandfile.test/test_agent_capabilities.py::test_project_file_shadowing_the_private_copy_names_that_file: the shadowed refusal names the project file.website/src/test/ErrorCard.test.tsx"sibling capability refusals" (one per code): readable copy, no code, no Resume, and the right button or none.website/src/test/transcriptRenderers.test.tsx"each sibling capability refusal routes to its own fix" (one per code): Continue is withheld, and the press opens the right place.website/src/test/useChatPageTurnRecovery.test.tsx: thememberfix opens the crewmate editor withoutpane=capabilities.website/src/test/transcriptRenderers.test.tsx"a capability refusal as the newest state owns recovery" anduseChatPageTurnRecovery.test.tsx"withholds the composer Resume while the newest row is": the composer's Resume yields for each code until a new turn opens.test/test_agent_capabilities.py::test_shadowing_file_is_named_as_it_is_on_disk[markdown|declared]: a.mdor declared-name shadow is named as it is on disk.test_chat_runner_coverage_turn_start.py::test_project_refusal_without_a_saved_project_names_no_empty_projectand the ErrorCard case "says another project when the member saved with no project to name": no empty project in the row.test/test_agent_capabilities.py::test_workspace_file_shadowing_the_private_copy_names_that_file_on_reconcile: the reconcile path's shadowed refusal names the file; the twoproject_identity_changedtests assert the saved project.prove.py --base origin/main: PROVEN. With the fix reverted, an assertion fails.Determinism: these tests use no timers, network or randomness. The touched vitest files passed 3 times in a row, then once more with
--sequence.shuffle. The backend tests passed twice. Each backend case also passed alone, run in reverse order.Manual verification
I rendered the four rows with
ErrorCardin a throwaway capture page (not committed), in light and dark themes, and checked the copy and buttons below. Still required, for a maintainer: trigger one live refusal on a real crewmate and check the row names that member. I did not do this, because it means breaking a real member's saved setup.Screenshots / video
After (dark):
After (light) and before
Fallback rows: a foreign-copy row with no member, and a project row with no saved project.
The composer under a refusal row: before, it still offered Resume; after, it falls back to Send and the card's own fix.
Before: each row showed only the bare code and a Resume button.
Related Issues
Closes #14005
Pattern harvest
Not generalizable: each refusal code needs its own fix, so this is per-code copy, not a rule a linter can check.
Checklist