Skip to content

fix: validate overmind socket liveness on start/stop#15

Open
bicabone wants to merge 3 commits into
mainfrom
fix/overmind-start-stop-reliability
Open

fix: validate overmind socket liveness on start/stop#15
bicabone wants to merge 3 commits into
mainfrom
fix/overmind-start-stop-reliability

Conversation

@bicabone
Copy link
Copy Markdown
Contributor

@bicabone bicabone commented Mar 3, 2026

Summary

  • Fix tctx start falsely reporting success when overmind child process dies immediately
  • Fix tctx stop failing on stale socket files left behind by overmind quit
  • Fix start/stop cycle breaking after first stop due to stale socket

Changes

  • start: Check socket liveness via overmind status before reporting "already running"; clean up stale sockets
  • start: Poll for socket existence (up to 2s) after daemonizing to verify overmind stayed alive; report actionable error if not
  • stop: Validate socket is live via overmind status before attempting quit; clean up stale sockets
  • stop: Remove socket file after successful overmind quit
  • test: Add status command to fake overmind stub

🤖 Generated with Claude Code

bicabone and others added 3 commits March 3, 2026 17:50
overmind start -D returns 0 even when the child process dies immediately,
and overmind quit leaves stale socket files behind. This caused start to
falsely report success and stop to fail finding a running server.

- Start now polls for socket existence after daemonizing to verify
  overmind actually stayed alive
- Start checks socket liveness via overmind status before reporting
  "already running", cleaning up stale sockets
- Stop validates socket is live before attempting quit
- Stop removes socket file after successful quit

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
- `tctx status` shows overmind process status or PID-based status
- `tctx logs` tails overmind echo output for the dev server
- Both report "not running" cleanly when server is down
- Cleans up stale sockets on status/logs checks

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
overmind status exits 0 even when processes are dead. Check for
"running" in the output instead. Also wait 1s after start before
verifying, and clean up dead overmind sessions on detection.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
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.

1 participant