Repository navigation
test: check the nested-empty array rows as the PostgreSQL 16/17 split, by server version - #217
Merged
Conversation
…, by server version
LiteralCorpusProbeTests failed on PostgreSQL 16 for all 28 value set types: its five nested-empty
rows ({{}}, {{},{}}, { {} }, {{{},{}}}, {{{}},{{}}}) asked for parity, while the sets read them as
{} as 17 and later do and 16 rejects them, the difference #128 decided and docs/value-sets.md states
(S21). Below 17, read from server_version_num, those rows now require exactly that: the server
rejects, the library reads {}, counted as documented. Anything else fails, including a library that
rejects them too, which on 16 used to count as both sides agreeing.
Measured with the shared container on 16.15, 17 and 18: the probe passes on each (on 16 it failed
28 rows before). Seeded with nested-empty reading removed (kept as
nested-empty-array-refused.patch), it fails 28 rows on each: on 16 as the documented split, on 17
and 18 as parity; `oracles.cs seeds nested-empty` reports it CAUGHT by LiteralCorpusProbeTests and
LiteralGrammarParityTests.
Closes #216
Co-Authored-By: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #216
Problem
On PostgreSQL 16,
LiteralCorpusProbeTestsfailed for all 28 value set types, all on the five nested-empty rows #128 added:{{}},{{},{}},{ {} },{{{},{}}},{{{}},{{}}}. The sets read these as{}, as PostgreSQL 17 and later do. PostgreSQL 16 rejects them. That's the difference #128 decided anddocs/value-sets.mdstates (claim S21). The probe asked for parity against whatever server the shared container ran. CI runs 17, so CI never saw the failure.Change
test/CodoMetis.ValueRanges.EFCore.PostgreSQL.IntegrationTests/LiteralCorpusProbeTests.cs:current_setting('server_version_num')), never the image name.candidates.jsonentry: this is a decided difference, not an unfixed defect.test/oracles/seeds/nested-empty-array-refused.patch, which stops the sets reading nested empties.Tests
The probe, run with the shared container on each version (swapped locally, not committed; #215 makes the version configurable):
dotnet run tools/oracles.cs seeds nested-empty: CAUGHT byLiteralCorpusProbeTests(28 of 49) andLiteralGrammarParityTests(NestedEmptyArrays_…).StringOverloadConventionTestscaught my first version, a genericTSelf.Parse(string)that would have bound to the span overload; it now goes throughStringOverloads.Parse.🤖 Generated with Claude Code