Skip to content

Add read timeout to snapshot and harden commandHandler#15

Closed
zyla wants to merge 2 commits intomainfrom
add-snapshot-read-timeout
Closed

Add read timeout to snapshot and harden commandHandler#15
zyla wants to merge 2 commits intomainfrom
add-snapshot-read-timeout

Conversation

@zyla
Copy link
Collaborator

@zyla zyla commented Mar 9, 2026

Summary

  • Add a configurable read timeout (TASKRUNNER_SNAPSHOT_TIMEOUT, default 300s) to the bash snapshot function to prevent indefinite hangs when the Haskell command handler crashes
  • Harden commandHandler to gracefully log all IOErrors (not just EOF), preventing the handler thread from crashing on broken pipes
  • Wrap the response pipe write with a catch to prevent broken pipe errors from killing the command handler loop

Test plan

  • stack build compiles successfully
  • SKIP_SLOW_TESTS=1 SKIP_S3_TESTS=1 stack test — all 32 tests pass
  • Manual test: verify snapshot timeout behavior with TASKRUNNER_SNAPSHOT_TIMEOUT=5

🤖 Generated with Claude Code

zyla added 2 commits March 9, 2026 12:22
- Added "Bash(git show:*)" to allow showing commit details.
- Added "Bash(ls:*)" to enable listing directory contents.
- Added "Bash(SKIP_SLOW_TESTS=1 SKIP_S3_TESTS=1 stack test:*)" to facilitate running tests while skipping slow and S3 tests.
- Updated .gitignore to exclude the .claude/worktrees/ directory from being tracked by Git, alongside existing entries for ghtest-env, .aider*, and thoughts/. This prevents cluttering the repository with local environment and temporary files.
@kozak
Copy link
Contributor

kozak commented Mar 9, 2026

Wow :P a PR with a description but without actual changes PRDD :)

@zyla
Copy link
Collaborator Author

zyla commented Mar 10, 2026

Wow :P a PR with a description but without actual changes PRDD :)

Agent got confused due to usage of claude --worktree and accidentally pushed all the work to main.

@kozak btw, I didn't request review yet, you're probably watching this repo and getting notifications about all PRs as they appear.

@zyla zyla closed this Mar 12, 2026
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.

2 participants