Repository navigation
Conversation
A raw launch command skipped the launch-brief arg that every named adapter template embeds, so the agent started at an empty prompt. Append it after the caller's own argv. Kimi rejects a positional prompt and keeps its post-readiness brief pointer, and a command that already names __BRIEF__ is left alone.
|
CI note: the only failing check, Behavior portable serial 1, fails in the unrelated timing-sensitive tests/fm-supervision-host.test.sh (host wake hand-off wait_until timeout); this PR does not touch that area. |
|
Speaking as Kun's firstmate: thank you @trillium, this is a clear, small change and the rovo catch from review is a good one. What I checked at head Contract-class: new-default (my own read). Main specifies the raw escape hatch as passing the captain's command through as written. The existing test says "nothing else may rewrite the captain's own command" and asserts that the raw command is unchanged. This PR changes that default for every raw launch, which is why the tests needed VISION:
CI: the only red is One ask, whenever you have time: the "live" rows in the description are the spawn tests with a fake pane. Could you do one real raw launch with an actual harness CLI (a generic one, plus kimi or rovo if you can) and post what the agent received? You could also re-raise through |
|
Thanks for the review. I don't have kimi or rovo installed, so I can't test the raw launch against either of those. |
Intent
Contribute this fix upstream to kunchenguid/firstmate as its own PR. Problem: a raw launch command (the unverified-adapter escape hatch, --harness '') skipped the launch-brief arg that every named adapter template embeds, so the agent started at an empty prompt. Change: bin/fm-spawn.sh appends the encoded launch-brief argument after the caller's own argv for raw commands. Deliberate decisions: Kimi is excluded (it rejects a positional prompt and gets its brief pointer after its readiness gate); a command that already names BRIEF is left alone. Tests: tests/fm-spawn-dispatch-profile.test.sh expectations updated for the appended argument; the chained raw launch case ends with '&& true' and the git-config probe with '; :' so the appended brief argument is harmless to the probed command. Scope is only this raw-launch brief append; no internal ticket references or AI attribution.
What Changed
bin/fm-spawn.sh: raw launch commands (the--harness '<cmd>'escape hatch) now get the encoded launch-brief argument appended after the caller's own argv, so the agent no longer starts at an empty prompt. Kimi is excluded (it rejects a positional prompt and gets its brief pointer after its readiness gate), and a command that already names__BRIEF__is left unchanged.tests/fm-spawn-dispatch-profile.test.sh: updated expectations for the appended brief argument. The chained raw launch case now ends with&& trueand the git-config probe with; :, so the appended argument is harmless to the probed command.Risk Assessment
✅ Low: Small, bounded change: the raw-launch brief append excludes kimi* and rovo*, skips commands that already name BRIEF, and the added rovo test runs the real spawn and asserts on the emitted command.
Testing
I ran the four tests this change touches against the real fm-spawn.sh and the emitted launch command, and all passed. They cover the appended brief on a generic raw launch, the rovo exclusion, the chained '&& true' case and the '; :' git-config probe. The full test file timed out, so the rest of it did not run. I did not drive a Herdr lab or a real harness CLI.
Pipeline
Updates from git push no-mistakes
✅ **intent** - passed
✅ No issues found.
✅ **Rebase** - passed
✅ No issues found.
🔧 **Review** - 1 issue found → auto-fixed ✅
bin/fm-spawn.sh:2906- The brief-append exclusion covers onlykimi*.rovohas the same constraint, and a raw launch whose first word isrovo(for examplerovo run --yolo) now gets the positional brief appended. The comments above the rovo template (about line 2850) record that a positional brief is dead-on-arrival for rovo: it loads, never enters a working state, and drops back to an idle shell within seconds. The later[ "$HARNESS" = rovo ]readiness-and-pointer path (about line 7354) is not gated onRAW_LAUNCH, so a raw rovo launch runs both the appended argument and the post-ready pointer. A command that worked before this change can now exit before the readiness gate. The change's "Deliberate decisions" name only Kimi, so adding rovo to the exclusion goes beyond the stated intent. That is why this is ask-user: the smallest remedy iskimi* | rovo)in the case at bin/fm-spawn.sh:2906.🔧 Fix applied.
✅ Re-checked - no issues remain.
✅ **Test** - passed
✅ No issues found.
Ran the four affected functions from tests/fm-spawn-dispatch-profile.test.sh through a temporary harness, since the full file exceeds the time budget: test_launch_preserves_inherited_git_config, test_active_dispatch_profile_allows_raw_launch_command, test_raw_rovo_launch_gets_no_positional_brief, test_chained_raw_launch_strips_ai_trailer_in_every_step✅ **Document** - passed
✅ No issues found.
✅ **Lint** - passed
✅ No issues found.
✅ **Push** - passed
✅ No issues found.