PG19 Beta3: adapt COPY failure tests to psql input draining - #8784
Conversation
Use program input only on PostgreSQL 19 for COPY failures that occur before COPY_IN, while preserving the original commands and diagnostics on PostgreSQL 16 through 18 through complete alternative expected files. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 809b79c3-b004-47c3-8e1d-4ba1af5b9eb5
Keep the existing expected files byte-identical and place the complete conditional legacy output in _1 alternatives, alongside the PG19 _0 alternatives. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 809b79c3-b004-47c3-8e1d-4ba1af5b9eb5
Include the inactive PG19 COPY commands echoed by psql in the complete legacy alternative expected files. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 809b79c3-b004-47c3-8e1d-4ba1af5b9eb5
Select the zero-row program input only for PostgreSQL 19 beta 3 and newer psql clients. Keep beta 1, beta 2, and older major clients on the legacy STDIN path. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 809b79c3-b004-47c3-8e1d-4ba1af5b9eb5
Allow PostgreSQL 19 beta 3 and newer client names to carry a whitespace-delimited packager suffix while continuing to reject beta 1, beta 2, devel, and other major versions. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 809b79c3-b004-47c3-8e1d-4ba1af5b9eb5
|
Validation note: PG18/17/16 full 38/38 results were captured at the immediately preceding gate commit; exact-final |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## pg19-support #8784 +/- ##
================================================
+ Coverage 88.69% 88.75% +0.05%
================================================
Files 289 289
Lines 65062 65070 +8
Branches 8200 8200
================================================
+ Hits 57709 57753 +44
+ Misses 4984 4954 -30
+ Partials 2369 2363 -6 🚀 New features to boost your workflow:
|
|
The PR states a goal of keeping both canonical |
|
Fundamental question, is the version gate actually needed ? What concrete regression does it prevent? Asking because #8780's own "Minimum Fix" is the unconditional
|
Use client-side zero-row PROGRAM input unconditionally for the four COPY failures that abort before COPY_IN. Keep their server-side failure injection and assertions unchanged, update the canonical echo output, and remove version-gated alternatives. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 809b79c3-b004-47c3-8e1d-4ba1af5b9eb5
|
Addressing the canonical/alternative-output question and the fundamental gate question: agreed—the gate was unnecessary. I removed the version gate, all conditional control lines, and all four alternative expected files. The four client-side zero-row inputs now use At exact head |
Colm (colm-mchugh)
left a comment
There was a problem hiding this comment.
Lgtm, one non-blocking comment nit.
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 809b79c3-b004-47c3-8e1d-4ba1af5b9eb5
0eb449c
into
pg19-support
Summary
PostgreSQL psql change
d6ab88d, first present in PG19 Beta3, changed failed COPY input draining. These four failure injections abort before COPY_IN, so inline\copy ... FROM STDINinput can consume following SQL in psql echo-all regression scripts.failure_copy_to_referenceinputs and one affectedfailure_copy_on_hashinput unconditionally with zero-row client-sideFROM PROGRAM 'true'\copy ... FROM PROGRAMis client-side and works consistently across the supported clients tested here, while supplying no rows for failures that occur before COPY_IN.Validation
Exact commit/tree validated:
4ee87f66cf0bfbff7447df0e5da9dc24e9f30fd1/aef35426123a65d79cda324a583736fab67b1cf8.Focused affected schedule:
Full
check-failure:PG19 Beta2 validation used the existing isolated local compatibility shim that omits the Beta3-only
output_plugin_librariestest setting; the shim is not part of this PR and was restored after validation.Final diff: 4 files, 8 insertions, 8 deletions.
Closes #8780