Skip to content

fix(cli): prevent subshell hang when capturing 'claude -p "check"' - #20

Open
jketreno wants to merge 1 commit into
terryso:developfrom
jketreno:develop
Open

fix(cli): prevent subshell hang when capturing 'claude -p "check"'#20
jketreno wants to merge 1 commit into
terryso:developfrom
jketreno:develop

Conversation

@jketreno

Copy link
Copy Markdown

Problem: The call to timeout 300s claude -p 'check' was not returning, however when I ran claude -p 'check' at the CLI, the process did return.

  • add run_claude_check() helper that prefers 'timeout --foreground'
  • fallback to 'script' (PTY) when a TTY is required
  • replace direct timeout calls and update debug message
  • prevents SIGTTOU/background-stop when used in command substitution

Problem: The call to `timeout 300s claude -p 'check'` was not returning, however
when I ran `claude -p 'check'` at the CLI, the process did return.

- add run_claude_check() helper that prefers 'timeout --foreground'
- fallback to 'script' (PTY) when a TTY is required
- replace direct timeout calls and update debug message
- prevents SIGTTOU/background-stop when used in command substitution
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