Repository navigation
chore: remove the Polyglot equivalence check - #175
Merged
Merged
Conversation
Real Snowflake results, the referee and the recorded receipts, are now the only bar for the Snowflake parser, so the forked code can diverge from Polyglot as it is fixed. - tools/sqlquack-polyglot-check, its expected differences, the polyglot-sql workspace dependency and its lockfile entries, and the polyglot-duckshop target are gone. CallMode::FaithfulWithSpans, which only the check used, goes with them. - polyglot-guard goes too: with no polyglot dependency left, nothing needs guarding. - syntax-coverage corpus-verdicts, part of check-ci, records whether SQLQuack parses each statement of the corpora under corpora/polyglot-check and fails on any change; make corpus-verdicts-baseline records a reviewed change. It keeps the two checks the removed crate ran that never involved Polyglot: the lossless tokens rebuild each statement byte for byte, and its located parse equals its faithful parse once spans are removed. - docs/syntax.md and docs/architecture.md no longer hold the parser to Polyglot's behaviour. The convert-layout change's exact-check failure was Polyglot's alone. SQLQuack parses the laid-out and compact DuckDB output of every recorded case to the same tree, apart from the raw text CREATE MACRO keeps. Polyglot refuses lambda parameters named by keywords and nested parenthesised UNION ALL operands, which DuckDB runs.
run_rust_tests.sh started the runs binary first and failed when it was missing; it was the removed exact check's integration test.
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.
Why
Real Snowflake results (referee and receipts) are now the only bar for the Snowflake parser, so the fork can diverge from Polyglot as it is fixed. The equivalence check held it to Polyglot and cost a heavy crate in every gate build.
The convert-layout PR's exact-check failure was Polyglot's alone. SQLQuack parses the laid-out and compact DuckDB output of all 11,354 recorded statements and macros to the same tree, apart from CREATE MACRO's raw text. Polyglot refuses keyword-named lambda parameters and nested parenthesised UNION ALL operands in IN, which DuckDB 2.0 runs.
Changes
polyglot-sqldependency (4 lockfile packages),polyglot-duckshop,CallMode::FaithfulWithSpansandpolyglot-guardwith its scripts and tests.syntax-coverage corpus-verdictsin check-ci: SQLQuack's own accept or refuse verdict on 68,094 statement and dialect pairs in corpora/polyglot-check, against coverage/syntax/corpus-verdicts.json; any change fails,make corpus-verdicts-baselinerecords one. It keeps the old crate's Polyglot-free checks: lossless tokens, and located parse equal to faithful. Corpora keep their names, so THIRD_PARTY_NOTICES holds.CallMode::Loweredgoes next PR; three ORDER BY ALL obligations in coverage/translation/obligations/query.toml cite the old check.Verification
make python-api, same orb, fresh target, two alternating runs each: main 469/458 s wall, 3,280/3,199 s CPU, 5.1 GB peak; branch 347/350 s, 2,582/2,576 s, 3.0 GB. Target 3.1 to 2.6 GB.make check-cipasses: corpus verdicts 68,094 as recorded, instruction counts within tolerance, syntax coverage 0 problems.