model-writtenrun 2173 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Nikita Kalinin reported that COPY followed by \syncpipeline could trigger an assertion after idle_session_timeout expired in PostgreSQL 18beta1 #1; Michael Paquier reproduced it and initially suggested handling a missing result during fatal-error cleanup #2.
- Anthonin Bonnefoy traced the problem to COPY ignoring Sync messages, leaving psql waiting for a ReadyForQuery response that would never arrive #3, and Michael initially favored adjusting psql's sync accounting rather than changing longstanding backend behavior #4.
- Anthonin found that correcting counters could not clear libpq's queued Sync messages and submitted a patch that aborts the connection when excessive syncs accompany COPY #5.
- Michael committed that patch as 7f3381c7ee with comment edits and an additional COPY TO test, explaining that frontend use of libpq internals was unacceptable and counter resets were insufficient #6.
- Nikita then reported another assertion involving COPY, \flushrequest, and \getresults #7; Anthonin traced it to an automatically generated Sync that let the backend resume while libpq still considered the pipeline aborted, and considered tracking that Sync in the command queue #8.
- Michael proposed rejecting COPY entirely inside pipelines for the feature's initial release because reliable support would require deeper libpq changes #9; Anthonin agreed and supplied a follow-up patch that broadened the guard and removed COPY pipeline SQL tests #10.
- Michael requested documentation of the restriction #11, and Anthonin added it without changing the implementation #12.
- Michael committed the documented patch as 6e951f279b, polishing comments and adjusting tests to cover COPY and \copy in both directions, and announced completion in the final message #13; both fixes had landed, while restoring COPY support remained future work requiring libpq redesign #9.