Repository navigation
fix(blocks): refuse a requested bind check when built without DuckDB - #347
Merged
Merged
Conversation
Without the engine feature, the printed-SQL check passed every statement that passed its lexical checks, so a conversion that asked for the bind check got none and was not told. The Databricks, PostgreSQL and SQLite pipelines always ask for it. The check now fails at the engine stage, and the statement is refused naming the missing engine. The browser playground, which runs the SQL in DuckDB-WASM, now skips the check explicitly. make engine-free runs the checking tests without the engine, which no other build does.
…ip advice The engine-free target now fails if its filter matches no test. The refusal message no longer tells the reader to skip the bind check, which the Databricks, PostgreSQL and SQLite pipelines do not offer.
kvlonge
enabled auto-merge
November 30, 2026 14:02
Split the test helper by feature instead of matching on the stage, and keep each doc comment to one line, as the layout rules require.
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
Built without DuckDB's
enginefeature, the printed-SQL check passed every statement that passed its lexical checks. A conversion that asked for the bind check therefore got none, and nothing said so. The Databricks, PostgreSQL and SQLite pipelines always ask for it, so linkingsqlbabel-convertwithout the engine would silently drop their bind check.Changes
check_printednow fails at theEnginestage ("this build has no DuckDB engine, so nothing can bind the SQL"), and the statement is refused instead of passing.skip_bind_check. Its behaviour is unchanged, because the old engine-free check was the lexical check alone.sqlbabel-convert's own tests enable the engine, as every other build of it does.cargo tree -e normalfor the crate still has no DuckDB.make engine-freealso runs the checking tests without the engine, which no other build does, and fails if none run.docs/architecture.mddescribes the new behaviour.Verification
cargo test -p sqlbabel-blocks --lib checking::without the engine: 4 pass. With the oldbound, 3 of the 4 fail (left: None, right: Some(Engine)), which is the silent pass this removes.sqlbabel-convertSnowflake analysis tests with the engine: 3 pass.make engine-freepasses, and fails with a filter that matches no test.-D warningson both crates,cargo fmt --check, the clutter guard.