Repository navigation
Add an Edit Queued button while Claude has queued prompts - #15258
teamleaderleo wants to merge 6 commits into
Conversation
Behind the new agentActions.promptEditing setting (off by default), the terminal's agent pill shows Edit Queued while Claude Code has prompts waiting in its input queue. Clicking it sends Up, Claude's own key for moving queued prompts back into the input. Claude records its queue in the session transcript as queue-operation lines (enqueue, then dequeue, remove, or popAll). ClaudeQueuedPromptLedger folds them; ClaudeQueuedPromptMonitor tails the transcript of the session the hook store marks active on the pane, only while Claude runs there with the setting on. Part of #15223. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository: manaflow-ai/cmux/.coderabbit.yaml Review profile: ASSERTIVE Plan: Advanced Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Dogfood build of cmux DEV pr-15258-66705c86.app The link opens this exact commit in the cmux dev menu bar app. The build starts on each push and the page waits until it is ready; a newer push replaces it. It signs in against production, so Cloud or backend changes still need a tagged build with a development backend. Dogfood tours of
|
Review fixes, checked against local Claude transcripts: - Claude queues its own task notifications and queued shell commands. Up doesn't pull those back and notifications are often never resolved, so the ledger ignores them. Folding 1,290 local sessions now leaves only 7 (all live) with anything queued, instead of a stuck count in finished sessions. - popAll is written once per pulled-back prompt with that prompt, so it is folded like remove. - Clicking Edit Queued no longer hides the button until the transcript says the queue emptied. If Up only moved the cursor in a multi-line draft, the button stays. Quick repeat clicks send one Up. - The monitor retries for up to 10 s when the transcript isn't recorded yet, stops cleanly mid-start, and reads the Claude hook store through RestorableAgentKind.hookStoreFileURL, which honors CMUX_AGENT_HOOK_STATE_DIR. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
# Conflicts: # cmux.xcodeproj/project.pbxproj
CI failure attributionCI failed on
Matched log linesNot re-run automatically: Written by |
…/agent-edit-queued
…/agent-edit-queued
Bugbot is paused — on-demand spend limit reachedBugbot uses usage-based billing for this team and has hit its on-demand spend limit. A team admin can raise the spend limit in the Cursor dashboard, or wait for the next billing cycle to continue. |
CountRecorder is main-actor isolated, so the test that creates it must be too; the app-host test build failed on it. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Bugbot is paused — on-demand spend limit reachedBugbot uses usage-based billing for this team and has hit its on-demand spend limit. A team admin can raise the spend limit in the Cursor dashboard, or wait for the next billing cycle to continue. |
|
Parked: stale stacked queued-prompt editing slice with base conflicts; needs a dedicated rebase pass. |
|
Reopen if needed. |
Summary
Second slice of #15223, stacked on #15234. With Settings > Terminal > Agent Edit Queued Button on (
agentActions.promptEditing, off by default), the terminal's agent pill shows Edit Queued while Claude Code has prompts waiting in its input queue. Clicking it sends Up, Claude's own key for moving queued prompts back into the input so you can edit them.queue-operationlines:enqueue(with the prompt), thendequeue(sent as the next turn),remove(absorbed into the running turn or delivered), orpopAll(pulled back with Up).ClaudeQueuedPromptLedger(CmuxAgentChat) folds those lines and ignores everything else.ClaudeQueuedPromptMonitorreads the hook store'sactiveSessionsBySurfacepointer for the pane, so a nestedclaude -prun in the pane is never mistaken for the pane's session. It folds the last 512 KB of that transcript, then only appended bytes, using the existingFileWatcher. It runs only while Claude is running in the pane with the setting on, and stops when either changes.Alt+Upedits it), but its transcript doesn't record it, so Codex gets no button yet.Testing
swift test --package-path Packages/Shared/CmuxAgentChat --filter ClaudeQueuedPromptLedgerTests(local, 3 passed): enqueue, absorbed remove, dequeue, and popAll; unrelated lines and stray resolutions are ignored; tracking is bounded.queue-operationlines in local Claude transcripts. The operations seen wereenqueue,dequeue,remove(reasonsabsorbed_mid_turnanddelivered_to_agent), andpopAll.cmuxTests/TerminalAgentQueuedPromptTests.swift(added, runs in CI):python3 scripts/verify-local.py(15/15) andpython3 tests/test_cmux_settings_supported_paths.pypassed.Changelog
Added: An optional Edit Queued button over a terminal moves Claude Code's queued prompts back into its input (Settings > Terminal > Agent Edit Queued Button).
Demo Video
Pending dogfood on a tagged build.
🤖 Generated with Claude Code
Summary by cubic
Adds an optional Edit Queued button to the terminal's agent pill while Claude Code has prompts waiting in its input queue. Off by default behind the new
agentActions.promptEditingsetting, clicking it sends Up, Claude's own key for moving queued prompts back into the input for editing.queue-operationlines (enqueue,dequeue,remove,popAll) from the active session's transcript and ignores Claude's own task notifications and queued shell commands, which Up doesn't pull back.Written for commit 66705c8. Summary will update on new commits.