model-writtenrun 5810 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Tom Lane reported that pg_dump accidentally appended a new query to an already executed query, wasting work while PQexec silently discarded the first result; his diagnostic patch included the fix and experimental PQexecParams substitutions, which found no additional cases in check-world #1.
- Tom Lane committed only the one-line buffer replacement from the attachment, with a backpatch to PostgreSQL 14; the experimental query-execution changes were omitted #1 ac7df108cf.
- After the commit, David G. Johnston suggested clearer buffer names or separate buffers but opposed broad refactoring, and Tom Lane agreed that invasive changes would be excessive despite PQexec masking this class of mistake #2 #3.
- Michael Paquier proposed a developer configuration setting and compilation flag to detect unwanted multiple-query execution #4.
- David G. Johnston questioned that proposal's practicality, explored direct query construction and warnings for discarded results, and favored code inspection and better test coverage; the concrete bug was fixed, while broader prevention remained unresolved at the thread's end #5 ac7df108cf.