Fix teammate pending status label#5
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThis PR coordinates fixes across dashboard pending-action tokening and mutation flows, restore-warning deduplication, persistence/graveyard handling, session capture and creation hardening, control retry tightening, debug notification matching, metadata parent validation, TUI status derivation, and tmux/statusline filtering, with accompanying tests. ChangesDashboard pending-actions and ops
Persistence and graveyarding
Multiplexer session/control flows
TUI rendering and statusline
Debug state
Metadata server
tmux control
Sequence Diagram(s)sequenceDiagram
participant Caller as MutationCaller
participant MutationRunner as runDashboard*Mutation
participant Pending as DashboardPendingActions
Caller->>MutationRunner: setPendingDashboard*Action(...) -> token
MutationRunner->>Pending: settleCreatePending(... expectedToken=token)
Pending-->>MutationRunner: clear only if token matches
MutationRunner->>Pending: clear*ActionIfToken(token) on finalize/error
Estimated code review effort🎯 4 (Complex) | ⏱️ ~45 minutes Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/multiplexer/dashboard-ops.ts`:
- Around line 254-256: The token used to clear pending dashboard actions is
captured before calling opts.onBeforeRequest, so if onBeforeRequest re-calls
host.setPendingDashboardSessionAction (e.g., in spawn/fork flows) the token
becomes stale and clearSessionActionIfToken (used later) can fail and leave the
row stuck; fix by deferring capturing the token until after opts.onBeforeRequest
completes (or re-read the current pending token) and then call
clearSessionActionIfToken with that fresh token; apply the same
single-pending-set pattern to forkDashboardAgentWithFeedback and update the code
paths around host.setPendingDashboardSessionAction, token, onBeforeRequest, and
clearSessionActionIfToken so the token used for clearing always matches the
latest pending action.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: c9b17a0a-0513-4e29-93c1-16c97b6672e2
📒 Files selected for processing (21)
scripts/tmux-control.shsrc/dashboard/pending-actions.test.tssrc/dashboard/pending-actions.tssrc/dashboard/ui-state-store.tssrc/debug-state.test.tssrc/debug-state.tssrc/metadata-server.test.tssrc/metadata-server.tssrc/multiplexer/dashboard-control.test.tssrc/multiplexer/dashboard-control.tssrc/multiplexer/dashboard-model.tssrc/multiplexer/dashboard-ops.test.tssrc/multiplexer/dashboard-ops.tssrc/multiplexer/persistence-methods.test.tssrc/multiplexer/persistence-methods.tssrc/multiplexer/session-actions.test.tssrc/multiplexer/session-actions.tssrc/multiplexer/session-capture.tssrc/multiplexer/session-launch.test.tssrc/statusline-model.tssrc/tmux/statusline.test.ts
Summary
Verification
Summary by CodeRabbit
Bug Fixes
Improvements
Tests