model-writtenrun 5051 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Andres Freund reported that interrupted TAP tests leave PostgreSQL instances running because pg_ctl detaches them from the terminal, and proposed INT/TERM handlers to trigger existing END cleanup; Michael Paquier acknowledged that END did not already handle this case #1 #2.
- Alvaro Herrera submitted signal handlers using exit and a separate tracing patch explicitly not intended for commitment; testing still left nodes running during startup and exposed a potentially separate looping psql process #3.
- Andres Freund tested the patch, traced incomplete cleanup to PIDs not yet recorded during startup and stop() calling BAIL_OUT, and proposed refreshing PIDs on abnormal exit, while reporting that some remaining processes were still unexplained #4.
- Peter Eisentraut suggested starting postmasters directly or disabling pg_ctl's setsid() behavior, but Andres Freund highlighted Windows startup complexity and argued that omitting setsid() would not resolve the process-parent issue; these alternatives were not adopted #5 #6.
- Alvaro Herrera revised the patch to use die in signal handlers, refresh PIDs during abnormal termination, and pass fail_ok through teardown_node so one shutdown failure would not prevent others; diagnostic tracing was omitted, and he acknowledged that some leftovers remained unexplained #7.
- Alvaro Herrera committed the revised patch with only comment and commit-message edits as 460c0076e8, without backpatching, and announced the improvement #8; Andres Freund thanked him in the final reply, with the residual process leaks and separate psql concern unresolved in this thread #9 #7 #3.