IW-599: start and open exit 0 without a terminal instead of failing the attach #688
No reviewers
Labels
No labels
agent-ready
bug
contract
documentation
duplicate
enhancement
good first issue
help wanted
invalid
needs-human
needs-input
question
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
iterative-works/iw-cli!688
Loading…
Reference in a new issue
No description provided.
Delete branch "IW-599"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
iw startandiw openno longer exit non-zero when standard input is not a terminal (CI container, agent shell). Before, they did all their work, then triedtmux attach, tmux refused, and the command reported exit 1.Now the session join checks for a terminal first. With no terminal it prints that the session is ready, why it does not attach, and the command to attach with, and exits 0. With a terminal, and inside a workspace, the behaviour is unchanged. The
--promptpath with no terminal still exits 5.Defects fixed
WorkspaceSession.joincalledenv.workspace.attachwith no terminal check, andenteredmapped the refusal toCommandResult.error.Stdin.isTerminalcapability (live probe:test -t 0with inherited stdin);joinguards only the attach branch.Testing
WorkspaceSessionTest, 1 each inStartHarnessTestandOpenHarnessTest.start.bats,open.bats,open-prompt.bats,start-prompt.bats,analyze.batsnow run with</dev/nulland assert the exit status (the old workaround comment instart.batsis gone). A new pty test inopen.bats(script -qec) covers the live probe returningtrue; a mutation check turned it red.Follow-ups filed
phase-prpush failure that matches the push timeout pattern.Release notes
See
project-management/issues/IW-599/release-notes.md(Czech).Closes #599
🤖 Generated with Claude Code
start and open try to attach without a TTY and fail, so a BATS test cannot assert their exit status Artifacts: - analysis.md - issue.md 🤖 Generated with Claude Code Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>start and open try to attach without a TTY and fail, so a BATS test cannot assert their exit status Artifacts: - tasks.md - review-state.json (tasks_ready) 🤖 Generated with Claude Code Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>Issue: IW-599 Phase: 1 - The session join attaches without checking for a terminal, and reports tmux's refusal as a command failure This commit marks the checkpoint for phase 1 context generation. Use dx-fix IW-599 to return to this point. 🤖 Generated with Claude Code Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>The session join attaches without checking for a terminal, and reports tmux's refusal as a command failure Artifacts: - phase-01-tasks.md 🤖 Generated with Claude Code Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>