Skip to content

Recover Claude loops and prevent duplicate Codex launches - #219

Merged
scgopi merged 4 commits into
mainfrom
issue-215-trust-dialog
Aug 30, 2026
Merged

scgopi merged 4 commits into
mainfrom
issue-215-trust-dialog

Conversation

@scgopi

@scgopi scgopi commented Aug 30, 2026

Copy link
Copy Markdown
Owner

Summary

  • pre-accept Claude folder trust for local, attached, and remote GraphCode launches while preserving existing config
  • surface zmx backend completion markers and exit codes instead of reporting exited sessions as idle
  • restart proven-dead sessions and retry node send delivery without killing live or unreachable sessions
  • cover trust persistence, exit rendering/presence, local recovery, and remote launch/send behavior

Tests

  • make test
  • make check
  • make build-cli
  • make build-daemon
  • focused ClaudeTrustTests, GraphcodeCommandTests, MessageAndSpawnTests, PresenceReportingTests, and RemoteSessionLaunchTests
  • real zmx task probe confirmed ZMX_TASK_COMPLETED:1 after an exit-1 command

Closes #215

  • prevent the Codex app/daemon first-attach race from typing the daemon launch wrapper into the Codex composer
  • cover unattended Codex goal/time attach behavior while preserving turn-based Codex and Claude launch behavior

@scgopi scgopi changed the title Recover Claude loops after startup exits Recover Claude loops and prevent duplicate Codex launches Aug 30, 2026
scgopi added 2 commits August 29, 2026 20:08
…ss, re-add exit surfacing, attach seeding, Codex deferral

Conflicts resolved in favor of main's #215 fix (husk-aware sessionTaskState,
aliveCheckCommand, ClaudeCodeTrust with permission preservation, guarded
respawn-on-send). Re-applied this branch's additive work on top:
- exit-code surfacing: local presence reads zmx's ended=/exit_code= via
  sessionTaskState (no scrollback marker grep), remote probe keeps the capped
  history check; displayState and CLI render 'session exited (N)'
- Claude folder-trust seeding on first app attach (now via ClaudeCodeTrust,
  plus its unexpected-shape guards)
- unattended Codex first-attach defers to the daemon (duplicate /bin/zsh fix)
Dropped the superseded kill-and-restart recovery and its onRecoverSession
plumbing: respawn-on-send now rides the merged ensure path, which is guarded
to unattended, unresolved loops and preserves resume continuity.
@scgopi
scgopi merged commit 477a6ab into main Aug 30, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Goal loop dies silently on Claude Code's 'trust this folder' prompt; stays idle and cannot be woken

1 participant