Skip to content

fix: skip Ink rendering for daemon-spawned sessions#540

Open
dzlobin wants to merge 1 commit intoslopus:mainfrom
dzlobin:fix/daemon-skip-ink
Open

fix: skip Ink rendering for daemon-spawned sessions#540
dzlobin wants to merge 1 commit intoslopus:mainfrom
dzlobin:fix/daemon-skip-ink

Conversation

@dzlobin
Copy link

@dzlobin dzlobin commented Feb 4, 2026

Summary

  • Threads startedBy field through Session class so launchers know if a session was daemon-spawned
  • Adds explicit startedBy !== 'daemon' guard to hasTTY checks across Claude, Codex, and Gemini launchers
  • Daemon sessions skip Ink rendering entirely since no human is watching the terminal

Context

Daemon-spawned processes typically already have process.stdout.isTTY === false, so the existing hasTTY check was already falsy. This adds a belt-and-suspenders explicit check for the case where a daemon process somehow has a TTY attached.

Test plan

  • Verified via daemon logs: TTY available: undefined, startedBy: daemon for daemon-spawned sessions
  • Verified terminal sessions still render Ink normally: TTY available: true, startedBy: terminal

🤖 Generated with Claude Code

Daemon-spawned sessions have no human watching the terminal, so
rendering Ink UI is unnecessary. This threads the startedBy field
through Session and adds an explicit guard to skip Ink when
startedBy === 'daemon', applied across Claude, Codex, and Gemini.

Generated with [Claude Code](https://claude.ai/code)
via [Happy](https://happy.engineering)

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