Skip to content

engine: treat exec.ErrWaitDelay as success in setup commands#42

Open
thewoolleyman wants to merge 1 commit intodanshapiro:mainfrom
thewoolleyman:fix-setup-waitdelay
Open

engine: treat exec.ErrWaitDelay as success in setup commands#42
thewoolleyman wants to merge 1 commit intodanshapiro:mainfrom
thewoolleyman:fix-setup-waitdelay

Conversation

@thewoolleyman
Copy link

Summary

  • Treat exec.ErrWaitDelay as success in setup commands, not failure
  • Background daemons (e.g. pg_ctl start) can hold stdout/stderr pipes open after the parent process exits successfully (exit code 0), causing Go's cmd.Wait() to return ErrWaitDelay after the configured WaitDelay. This is not a real failure.
  • Adds a test that spawns a background child holding pipes open and verifies the setup command succeeds

Dependency

Note: PR #41 (fix pre-existing test failures, add GitHub Actions CI) should be merged before this PR to avoid conflicts, as this PR is based on top of those changes.

Test plan

  • Existing TestSetupCommands_* tests pass
  • New TestSetupCommands_BackgroundDaemonDoesNotFail test passes
  • CI green on fork

🤖 Generated with Claude Code

Background daemons (e.g. pg_ctl start) can hold stdout/stderr pipes
open after the parent exits successfully, causing Go's cmd.Wait() to
return ErrWaitDelay. This is not a real failure — the setup command
itself completed with exit code 0.

Co-Authored-By: Claude Opus 4.6 <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