Repository navigation
fix(runtime): accept Muse's composer when the voice-input label is absent - #25695
Conversation
Walkthrough
Priority: Severity of issue fixed: Medium Merge Risk:
|
There was a problem hiding this comment.
ℹ️ No critical issues — the change is correct and the behavior delta is exactly the intended Linux screen. One process note inline.
Reviewed changes
- Linux Muse readiness now accepted:
findMuseReadyPromptIndexreturns the latestmuse codebanner index whenever a❯follows it, dropping thevoice/inputrequirement that only macOS/Windows paint. Both the old and new predicates return the banner index, so the only delta is which screens qualify. - Tests: a Linux ready-screen unit fixture, a live-PTY
tui-idletest for the same screen, a Windows voice-label regression, and two negative tests (banner without a composer, composer above a newer banner). - Ordering preserved:
isUnblockedAfterstill vetoes a blocked dialog painted after the banner, andfindDismissedStartupModalIndexstill dismisses a trust dialog only when a later banner (plus composer) repainted below it.
ℹ️ Nitpicks
terminal-wait-detection.test.ts:559— the test is named for the Windows voice-input shortcut label, but the predicate no longer reads that label; it passes with or without the line, so it does not actually pin the label behavior. Rename to describe the Windows ready screen, or assert the fixture still contains the label if that is the intent.
deepseek-v4.1-flash (free via Pullfrog for OSS) | 𝕏
| // Linux ready screen (Muse Code 1.4.3): same `❯` composer and status line, but Linux builds | ||
| // never paint the "Voice input" ruler above the composer. | ||
| const MUSE_READY_SCREEN_LINUX = [ | ||
| ' Muse Code 1.4.3', | ||
| '─────────────────────────────────────────────────────────────────────────', | ||
| '❯ ───────────────────────────────────────────────────────────────────────', | ||
| ' muse-spark-1.3 · high · ~/projects/demo · YOLO' | ||
| ] |
There was a problem hiding this comment.
The Linux screen here is transcribed by hand, so the rule is pinned to a remembered screen rather than captured bytes. AGENTS.md and docs/reference/agent-pty-transcript-capture.md require readiness rules be written against a recorder capture, and this predicate already has such a lane (muse-readiness-transcript.test.ts + __fixtures__/muse-empty-folder-ready.txt). Consider recording a Linux ready screen and extending that suite; the line array can stay as the fast unit test.
Technical details
# Capture the Linux Muse ready screen as a transcript
## Affected sites
- `src/main/runtime/terminal-wait-detection.test.ts:532-537` — `MUSE_READY_SCREEN_LINUX`, hand-transcribed fixture.
- `src/main/runtime/terminal-wait-name-only-idle.test.ts:38-43` — `MUSE_READY_TAIL_LINUX`, the same lines duplicated.
## Required outcome
- The `❯`-only predicate is pinned to bytes a real Linux Muse CLI emitted, fed through `onPtyData`, matching the existing Muse readiness suite.
## Suggested approach (optional)
- Record with `node config/scripts/capture-agent-pty-transcript.mjs --name muse-linux-ready -- muse --provider echo --trust-workspace`, scrub per the doc, and add a case to `muse-readiness-transcript.test.ts` (advance the version in the sidecar note).
## Open questions for the human (optional)
- Is a hand-transcribed fixture acceptable for this rule, or is a committed Linux capture expected?…sent Muse labels its composer's top rule "Voice input" only where voice is available, so on Linux the readiness predicate never matched and worker-start timed out at agent_readiness. Keep the voice-label match and also accept the composer itself: a rule (two or more rule chars) directly before the prompt glyph after the latest Muse banner, so a shell prompt like '~/app ❯' or '╰─❯' under a printed banner is still not ready. Fixes stablyai#25005 Co-authored-by: j33pia <[email protected]> Co-authored-by: Nawapat Buakoet <[email protected]>
fe4a8ea to
17a3474
Compare
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to GitHub limitations.

Minor · Constrain the Muse composer match to its rendered box. · terminal-wait-detection.ts:132-143
src/main/runtime/terminal-wait-detection.ts:132-143
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick winConstrain the Muse composer match to its rendered box.
MUSE_COMPOSER_REuses\s*, which can consume line breaks. After the latestMuse Codebanner, a divider followed by a later non-composer❯can therefore satisfy the regex.isUnblockedAfterdoes not reject this case, and a quiet Muse screen can becomeready-strong. This violates the existing contract that shell prompts are not ready.Preserve the valid same-line form and the fixture's three-line composer form, but reject arbitrary intervening lines.
Suggested fix
-const MUSE_COMPOSER_RE = /\u2500\u2500\s*\u276F/ +const MUSE_COMPOSER_RE = + /\u2500\u2500(?:[ \t]*\u276F|[ \t]*\r?\n[ \t]*\u276F[ \t]*\r?\n[ \t]*\u2500\u2500)/

Review info
-
Run configuration-
- Source mode: Auto
- Repository: Unavailable
- Branch: Unavailable
- File: No configuration file from this repository applied
- Commit: Unavailable
- Layers: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
1d021568-7981-4fbf-9d88-3b40d6877cf7
Files selected for processing: 1-
src/main/runtime/terminal-wait-detection.ts
Files skipped from review as they are similar to previous changes: 1-
- src/main/runtime/terminal-wait-detection.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 1 remain after this review.
-

ELI5
Before Orca hands a task to a Muse agent, it waits until Muse's screen shows its input box. Orca only recognized that box when it carried a "Voice input" label. Muse only adds that label where voice works, so on Linux it never appears, Orca kept waiting, and every Muse worker start timed out. Orca now recognizes the input box with or without the label.
What Changed
orca orchestration worker-start --agent musefailed withagent_readiness · timeouteven though Muse was idle at its❯composer. macOS/Windows (voice label shown) worked.Muse Codebanner.findMuseReadyPromptIndexinsrc/main/runtime/terminal-wait-detection.tsrequiredvoice+input+❯after the lastmuse code. That match is kept (so narrow panes that clip the rule after the label still match), and it now also accepts the composer itself:❯directly after a rule of two or more─(/──\s*❯/). Everything around it is unchanged: the latest-banner anchor, the quiet-body gate beforetui-idlesettles, and blocked-dialog ordering.Why
The voice label is a platform-dependent decoration, not a readiness signal. Accepting a bare
❯(as one alternative proposed) would read a shell prompt left under an exited Muse's banner (~/app ❯, starship/pure╰─❯) as ready, so the new match requires a real composer rule before the prompt. Platform-gating the voice requirement was rejected because Orca can drive a Muse running on a different OS than the client (SSH / paired hosts).Linked Issue
Fixes #25005
Original fix by @j33pia in #25695; final version reworked during the bug bash. Also thanks to @BeamNawapat for #25047, which targeted the same bug.
Reported by @pollackscience
Visual Proof
N/A: no UI change. This only changes when the runtime considers a Muse terminal ready to receive a task.
Testing
Repro: on
main, the new unit case (──…❯ ──…underMuse Code 1.4.2, no voice label) and the new captured-bytes transcript__fixtures__/muse-no-voice-footer-ready.txt(Muse 1.4.0 withMUSE_EXPERIMENTAL_VOICE=0, so the composer rule has no voice label, as on Linux) both fail (expected false to be true/Error: timeout).With the fix: both pass, and new negative cases (
~/app ❯and╰─❯under a printed Muse banner) stay not-ready.pnpm test src/main/runtime/terminal-wait-detection.test.ts src/main/runtime/cline-screen-readiness-transcripts.test.ts: 128 passed.oxlint, oxfmt, anti-slop / code-quality / ast-grep gates, changed-code quality gate, and the flaky-test ratchet pass (the stale
test-timeout-needs-reasoncount for the transcript test is pruned).Platforms: tested on macOS; the predicate is platform-neutral text matching, so Linux/Windows and local/SSH behave the same.
I manually tested these changes locally
Automated tests added/updated, or explained why not below
Agent skill upstream boundary
Notes
Muse-only predicate change; no new inputs, process, file or network access. Backwards compatible: every screen that was ready before is still ready. No mobile surface.
Checklist
N/Awith reasonpnpm lint,pnpm typecheck,pnpm test, andpnpm buildpass (or CI will cover; local preferred)