Repository navigation
fix(runtime): deliver Devin launch prompts via argv instead of stdin-after-start - #33349
Merged
Merged
Conversation
…after-start The stdin-after-start follow-up polls for the foreground process name, and the devin wrapper execs into `devin acp` almost instantly — so the prompt was written ~30ms after launch, while Devin was still printing its banner and its REPL input loop did not exist yet. The write was dropped (or stranded as an unsubmitted draft) while the launch reported success. Switch Devin to argv delivery with the documented `--` separator: the prompt rides the launch command itself, which the reporter verified end-to-end (3/3 runs, ~3s to submission) against the measured acceptance windows — a stability heuristic cannot hit the ~1s early window without sliding into the discard zone. No-prompt launches are unaffected (both modes take the same early exit), and the reviewer-facing draft semantics stay on the draft path where they belong. Fixes #26302 Generated-by: GLM-5.3-Flash (ZCode)
…an pin followupPrompt: null already guarantees no PTY write; the shared startup-plan test pins Devin's argv shape. Co-authored-by: ggbdpq <67929842+ggbdpq@users.noreply.github.com>
Contributor
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 2 minutes. View limit details
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 |
This was referenced Oct 25, 2026
10 of 11 tasks
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.
ELI5
When Orca launched Devin with a prompt, it typed the prompt into the terminal about 30ms after Devin started. Devin wasn't reading input yet, so the prompt was lost even though the launch said it worked. Now the prompt goes on Devin's command line (
devin … -- '<prompt>'), which Devin documents as "starts an interactive session" with that prompt, the same way Orca launches Trae, Grok, and Prime Agent.Root cause
Devin used
promptInjectionMode: 'stdin-after-start'. The readiness poll waits for the foreground process to be nameddevin, and that is true right away, before Devin's REPL is reading input. So the follow-up write got there first and was dropped.Upstream contract (installed
devin3000.10.31,devin --help):Usage: devin [OPTIONS] [PATH]... [-- <PROMPT>...] [COMMAND][PROMPT]... Your prompt (use -- before the prompt). Starts an interactive session. Use -p/--print for non-interactive mode.Devin has no
--promptflag. The positional prompt after--is the documented interactive form, and--prompt-fileis the only other way to seed one.What changed
src/shared/tui-agent-config.ts: Devin now usespromptInjectionMode: 'argv'withargvPromptSeparator: '--'.followupPrompt: null.tui-agent-startup.spec.ts, and dropped its 81-line runtime spec. That spec duplicated the plan pin, becausefollowupPrompt: nullalready rules out a PTY write.buildAgentDraftLaunchPlan) don't change either: Devin has no draft flag or env var, so drafts still use the paste path and do not auto-submit.How verified
Ran the real Devin CLI (logged in) in a Python PTY harness, 120x40 TERM=xterm-256color, with the prompt "Compute 17*23 and reply with only the number, no tools.":
devin, then prompt+CR written at 30ms (trusted dir)devin --permission-mode bypass --respect-workspace-trust false -- '<prompt>'(exact Orca default args, fresh untrusted dir)391, OSCDevin finisheddevin -- '<prompt>'without Orca's default args, fresh dirChecks:
pnpm test src/shared/tui-agent-startup.test.ts src/renderer/src/lib/tui-agent-startup.test.ts src/shared/tui-agent-prompt-transport.test.ts: pass.src/main/runtime/orca-runtime.test.ts: 2 failures in existing-folder import, and the same 2 fail on maindb8fc6d0cc9bwithout this change.pnpm tc: pass.pnpm run check:code-quality:changed: pass.Cross-platform / remote / mobile
quoteStartupArg(POSIX, PowerShell literal, cmd caret-escaping), the same path as the other agents that use the--separator (trae, grok, prime-agent). On cmd.exe, multi-line prompts have the same limitation as every other argv agent.Risk
Low. The change is a single config line. If a Windows PowerShell shim ever stripped
--, Devin would read the prompt as[PATH]and open Desktop. I haven't verified this on Windows; trae, grok, and prime-agent already use the same separator.Fixes #26302
Supersedes #26387
Co-authored-by: ggbdpq 67929842+ggbdpq@users.noreply.github.com