fix: support Grok 0.2.111 busy-state signals#985
Open
jeremiahoclark wants to merge 4 commits into
Open
Conversation
5 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.
Intent
Add Grok CLI as a fully verified firstmate harness adapter so project tasks can be launched, supervised, resumed, validated, and stopped through the normal lifecycle. Start from the existing smoke evidence but empirically verify terminal mechanics in a disposable worktree directory, including autonomous launch and permission flags, positional prompt submission, busy and idle signatures, interrupt and clean exit, resume, dialogs, and no-mistakes skill invocation. Implement Grok anywhere the supported harness set is enumerated, including launch, detection, session locking, supervision busy signatures, turn-end handling, adapter documentation with date and CLI version, and focused tests, without changing unrelated adapters. On the current main baseline most Grok enumeration and lifecycle support already existed; live Grok 0.2.111 verification exposed a changed busy footer and interrupt key, so this branch updates the shared tmux and watcher busy signature from Ctrl+c:cancel to Esc:cancel, refreshes verified adapter facts, and adds focused regression coverage while preserving the existing launch and hook mechanics.
What Changed
Esc:cancelbusy marker while preserving support for the legacyCtrl+c:cancelfooter across tmux, watcher, crew-state, and supervision paths.Risk Assessment
✅ Low: Captain, the change is narrowly scoped, preserves both verified Grok busy markers, centralizes runtime detection, and introduces no substantiated regression.
Testing
Startup, runtime version, target identity, focused Grok lifecycle tests, adjacent supervision/state regressions, private-tmux evidence, and a credentialed live Grok 0.2.111 busy/interrupt/idle flow all passed; an extra unchanged-path
/exitsetup did not reach a fresh idle composer within its bounded window and was excluded from acceptance evidence, all test-owned temporary files were removed, and the worktree finished clean.Evidence: Live Grok 0.2.111 TUI busy/interrupt evidence
Evidence: Base-versus-target classification comparison
Evidence: Production tmux classification transcript
Evidence: Focused Grok harness test transcript
Pipeline
Updates from git push no-mistakes
✅ **intent** - passed
✅ No issues found.
✅ **Rebase** - passed
✅ No issues found.
🔧 **Review** - 3 issues found → auto-fixed ✅
bin/fm-tmux-lib.sh:66- Replacing the old signature drops compatibility with previously verified Grok versions, while no spawn/bootstrap path requires Grok >=0.2.111. Older installations still launch, but active turns usingCtrl+c:cancelappear idle to watcher, crew-state, and away-mode fallbacks. Decide whether to preserve both signatures or enforce a minimum Grok version.docs/configuration.md:435- The documentedFM_BUSY_REGEXoverride still contains onlyCtrl\+c:cancel. Because this override replaces the new default everywhere, users following the configuration reference will break busy detection on Grok 0.2.111. Update it to the selected current or dual-version pattern.bin/fm-watch.sh:108- Use the already-loaded shared default (FM_TMUX_BUSY_REGEX_DEFAULT) here instead of duplicating the regex literal. This non-functional simplification prevents watcher detection from drifting from crew-state and daemon consumers.🔧 Fix: Captain, preserve Grok busy markers across versions
✅ Re-checked - no issues remain.
✅ **Test** - passed
✅ No issues found.
bin/fm-session-start.shgrok --versionbin/fm-test-run.sh tests/fm-grok-harness.test.shbin/fm-test-run.sh tests/fm-tmux-submit-busy.test.sh tests/fm-crew-state.test.sh tests/fm-watch-triage.test.shbin/fm-test-run.sh tests/fm-spawn-dispatch-profile.test.sh tests/fm-supervision-instructions.test.shPrivate-socket tmux verification using productionfm_pane_is_busyagainst Grok 0.2.111, legacy, and idle footersBase-versus-target classification usinggit show 10ee7797e50c88c9865d8fb382cdfee5c2b8bcd1:bin/fm-tmux-lib.shand targetbin/fm-tmux-lib.shCredentialed, isolated Grok 0.2.111 TUI verification of positional launch, live busy footer, production classification, Escape interrupt, and post-interrupt idle classificationgit diff --check 10ee7797e50c88c9865d8fb382cdfee5c2b8bcd1..c539c29fb553363c24f8cd81c2dd6b0b2a7acbd0Finalgit status --short --untracked-files=allandgit rev-parse HEADcleanup/identity audit✅ **Document** - passed
✅ No issues found.
✅ **Lint** - passed
✅ No issues found.
✅ **Push** - passed
✅ No issues found.