hermes-agent/ui-tui/src/__tests__
Ben e71f9ad0bb fix(tui): close busy-flag race that stuck queue-mode back-to-back sends
Under display.busy_input_mode: queue, sending two messages back-to-back
hung the session on 'Analyzing…' until a manual Ctrl+C.

The submit path only marked the session busy inside the .then of an
async input.detect_drop RPC. dispatchSubmission routes queue-vs-send on
getUiState().busy, so a second Enter inside that RPC window read
busy===false and raced a second prompt.submit down the send path
instead of enqueuing locally. The gateway accepts the mid-turn submit
as a success ({status:'queued'}, not an error), and the client's only
re-queue recovery is gated on catching a 'session busy' error — which
never fires — so the message became invisible to the client-side drain
effect and the UI stayed busy forever.

Extract the ready-prompt submit into a pure submissionCore module and
mark the session busy synchronously at the choke point, before the
detect_drop round-trip, closing the gap for every caller (mainline
submit, queue-edit picks, drain, interpolation). Verified the real
gateway already queues+drains both turns correctly, so the fix is
purely client-side. Adds submissionCore.test.ts whose regression
assertions fail without the synchronous busy and pass with it.
2026-07-01 00:24:40 -07:00
..
activeSessionSwitcher.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
appChromeStatusRule.test.tsx style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
appChromeStatusRuleDevCredits.test.tsx style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
approvalAction.test.ts fix(approval): carry allow_permanent to TUI + desktop approval prompts 2026-06-11 18:23:59 -05:00
asCommandDispatch.test.ts feat(tui): wire /rewind through command.dispatch + prefill payload (#21910) 2026-06-01 01:22:38 -07:00
billingCommand.test.ts feat(billing): /billing terminal billing — interactive TUI + CLI client (#45449) 2026-06-19 01:53:32 +05:30
blockLayout.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
brandingMcpCount.test.ts fix(tui): MCP headline counts connected servers, not disabled ones (#48402) 2026-06-18 05:41:19 -07:00
clipboard.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
completionApply.test.ts fix(tui): don't make Enter swallow trailing-space-only slash completions (#48425) 2026-06-18 11:04:59 -05:00
constants.test.ts
createGatewayEventHandler.test.ts feat(moa): render reference-model blocks in TUI and desktop, not just CLI (#53855) 2026-06-27 18:46:20 -07:00
createSlashHandler.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
creditsCommand.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
cursorDriftRegression.test.ts review(tui): route cursorLayout through @hermes/ink wrapAnsi shim (Bun runtime parity) 2026-05-17 11:52:21 -05:00
details.test.ts
emoji.test.ts
externalLink.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
forceTruecolor.test.ts fix(tui): harden Terminal.app render behavior 2026-05-16 22:51:51 -05:00
gatewayClient.test.ts fix(tui): defer buffered gateway events to stop dashboard chat #301 (#36658) 2026-06-28 14:18:47 +05:30
gatewayRecovery.test.ts fix(tui): auto-recover session on unexpected gateway death (+ persist lifecycle breadcrumbs) (#35893) 2026-05-31 10:36:57 -05:00
gracefulExit.test.ts fix(tui): restart dashboard chat on idle exit hotkeys 2026-06-19 12:02:22 +05:30
journeyCommand.test.ts feat(journey): CLI + TUI learning timeline (/journey) 2026-06-30 04:44:58 -05:00
markdown.test.ts fix(tui): preserve dunder identifiers in markdown 2026-05-19 00:06:08 -07:00
mathUnicode.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
memoryMonitor.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
messageLine.test.ts fix(tui): delineate assistant responses from details (#31087) 2026-05-25 10:23:03 -05:00
messages.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
modelPicker.test.ts fix: also preserve provider selection on Esc-clear-filter path 2026-06-27 04:33:48 +05:30
orchestratorPromptSession.test.ts feat: add TUI session orchestrator 2026-05-26 20:51:59 -07:00
osc52.test.ts
parentLog.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
paths.test.ts feat(tui): include session name in the terminal titlebar (#43188) 2026-06-10 11:24:01 +10:00
petPane.test.tsx feat(tui): float petdex pet bottom-right with responsive text reservation 2026-06-30 15:41:44 -05:00
platform.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
precisionWheel.test.ts fix(tui): steady transcript scrollbar (#20917) 2026-05-06 14:50:31 -07:00
prompt.test.ts fix(tui): termux-gate composer rendering tweaks for Ink TUI 2026-05-21 19:08:38 -07:00
providers.test.ts
reasoning.test.ts fix(tui): anchor splitReasoning unclosed-tag regex to start of input (#29426) 2026-05-20 14:09:38 -05:00
rpc.test.ts
scroll.test.ts fix(tui): refresh scroll height at cached bottom 2026-05-07 05:48:19 -07:00
slashParity.test.ts test(tui): regression test for /q alias resolving to queue (#31983) 2026-05-25 12:48:46 +00:00
spawnHistoryStore.test.ts fix(tui): handle timeout/error subagent statuses in /agents (#26687) 2026-05-15 20:19:02 -05:00
stateIsolation.test.ts
statusBarTicker.test.ts feat(tui): segment turns with rule above non-first user msgs; trim ticker dead space (#21846) 2026-05-08 05:12:09 -07:00
statusRule.test.ts feat(tui): track background subagents in the status bar (#51485) 2026-06-23 11:32:00 -07:00
streamingMarkdown.test.ts
subagentTree.test.ts fix: stop reporting cache-hit rate and cost across all UI surfaces (#52717) 2026-06-25 15:21:22 -07:00
submissionCore.test.ts fix(tui): close busy-flag race that stuck queue-mode back-to-back sends 2026-07-01 00:24:40 -07:00
syntax.test.ts
terminalModes.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
terminalParity.test.ts
terminalSetup.test.ts
termux.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
termuxComposerLayout.test.ts fix(tui): termux-gate composer rendering tweaks for Ink TUI 2026-05-21 19:08:38 -07:00
text.test.ts fix(tui): stop persisting full tool output in trail lines (silent OOM death) 2026-06-03 06:00:22 -07:00
textInputBurstInput.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
textInputCursorSourceOfTruth.test.ts fix(tui): keep Ink displayCursor in sync with fast-echo writes so cursor stops drifting (#26717) 2026-05-16 00:28:12 -05:00
textInputFastEcho.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
textInputLineNav.test.ts
textInputPassThrough.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
textInputRightClick.test.ts fix(tui): right-click copies selection, only pastes when no selection 2026-05-10 16:06:33 -07:00
textInputWrap.test.ts review(tui): route cursorLayout through @hermes/ink wrapAnsi shim (Bun runtime parity) 2026-05-17 11:52:21 -05:00
theme.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
turnControllerNotice.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
turnStore.test.ts
useCompletion.test.ts fix(tui): complete absolute paths as paths 2026-05-04 16:14:40 -07:00
useComposerState.test.ts
useConfigSync.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
useInputHandlers.test.ts fix(tui): restart dashboard chat on idle exit hotkeys 2026-06-19 12:02:22 +05:30
useQueue.test.ts
useSessionLifecycle.test.ts Settle TUI resume scroll after hydration 2026-06-26 01:05:26 -07:00
useVirtualHistoryHeights.test.ts
viewport.test.ts
viewportStore.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
virtualHeights.test.ts fix(tui): clear selection on right-click copy + group transcript blocks 2026-06-02 22:03:38 -05:00
virtualHistoryClamp.test.ts
virtualHistoryOffsetCache.test.ts style(desktop,tui): fix all lint/type/formatting issues 2026-06-26 01:04:33 -05:00
wheelAccel.test.ts