Fix reliable dashboard terminal submit - #952
Merged
Merged
Conversation
This was referenced Jul 31, 2026
olegbrok
force-pushed
the
agent/dashboard-terminal-submit
branch
from
July 31, 2026 16:16
a005b02 to
9c657f6
Compare
Owner
Author
Live RC E2E arbiter — terminal PASSExact head: Barsik independently ran the built worktree through an isolated scratch daemon/data directory and Playwright Chromium against a live tmux/CC pane; production was untouched. Result: 10/10 PASS.
Murzik's terminal exact-head gauntlet and all required CI are also PASS. Scope remains dashboard |
bradbrok
marked this pull request as ready for review
July 31, 2026 16:46
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Root cause
The terminal serialized each text/Enter fetch through a promise chain. Closing or switching the terminal incremented
sendEpoch, deliberately dropping links that had not started. With a slow text request, the queued Enter never initiated, leaving visible text unsubmitted. A pre-fix positive control produced only[{text: "rapid"}]; Enter was absent.The replacement starts Enter synchronously and includes every unacknowledged prior event. The tmux session serializes and de-duplicates cumulative batches by terminal-client sequence, including partial receipts, while the component continues to snapshot the original pane target.
Gauntlet fix
The first review head let stale request callbacks overwrite newer state. A late old success could clear an exhausted pending Enter error, while a late old failure could display after a newer cumulative Enter had succeeded. Success now clears the UI only when no event remains pending, and failed requests are suppressed when their maximum sequence is already globally acknowledged. Both response-order races have regressions.
Scope boundary
This fixes only the dashboard terminal path:
TmuxPaneModal → POST /tmux/pane/keys → send_pane_key_events. Wake-prompt delivery is a separate_deliver_turn → paste_textpath using bracketed paste, fixed delays, and tmux Enter; it does not share this keepalive/sequence sender and is intentionally not claimed fixed here. A live 08:59 Mini wake loss after pre-prompt/effort ultracoderemains known-uncovered composer evidence.Validation
npm test: 5/5npm run build: passPINKY_SHARED_MCP=0 uv run pytest -q tests/test_agent_status.py::TestTmuxPaneKeys: 11/11uv run pytest -q tests/test_tmux_session.py: 363/363uv run ruff check .,uv lock --check, compileall, andgit diff --check: pass0d, byte-identical in shape to plaintmux send-keys -l ...; send-keys Enter; no escape/control residue or paste wrapperCloses #951