STET

flux-pr-1628

sqlparser-rs (Rust) · W1 · GPT-5.1 Codex Mini

pass_with_warn

Tests passed. 1/1 commands passed. Strength: strong.

100.0% run pass rate
Tier 1
primary testspasseddecision conflictnon equivalentfail
env PATH=/root/.cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin cargo test --all-features
gold passagent pass

Partial score: 1/1

Publishable: yesCache: miss

Trajectory

unknown · partial order only

Canonical trajectory missing; showing coarse derived order only.

patch written
Patch captured
#1

Stet captured agent.patch for this trial.

validation
Tests passed
#2
equivalence
Equivalence judgment
#3

non_equivalent

code review
Code review judgment
#4

fail

decision
Final decision
#5

pass_with_warn

Quality

equivalence
non_equivalent
95% confidence
code review
fail
3 findings
footprint
low (0.13)
behavioral
0.0%
cost
$1.32 · 3.7M

Equivalence Reasoning

behavioral

The patch does not implement the core ClickHouse `INSERT ... SETTINGS ... FORMAT ... <input data>` behavior. It parses `SETTINGS`/`FORMAT` only at the end of `INSERT` parsing (after source/query), so statements like `INSERT INTO tbl SETTINGS ... FORMAT JSONEachRow {...}` are not handled correctly. It also reuses `FormatClause` (identifier/null only) instead of supporting input format payload expressions after `FORMAT`, so non-standard input data forms (e.g., JSONEachRow rows) cannot be parsed/round-tripped as intended.

Code Review

correctness: 1/4introduced bug risk: 1/4edge case handling: 0/4maintainability idioms: 2/4

The patch only partially addresses the feature and misses the core ClickHouse INSERT FORMAT/SETTINGS syntax and AST representation needed for correct parsing and round-tripping.

3 findings
SETTINGS/FORMAT are parsed in the wrong position for ClickHouse INSERT
major

The parser reads settings/format only after parsing source/on/returning, so it does not support the intended ClickHouse form where SETTINGS/FORMAT appear directly after table/columns (including FORMAT-based input statements without a SELECT/VALUES query).

src/parser/mod.rs:12128
FORMAT is modeled with the wrong AST type
major

The patch uses FormatClause (identifier/null) for INSERT instead of an input-format clause that can carry values/expressions, so statements like FORMAT JSONEachRow followed by data expressions cannot be represented or round-tripped.

src/ast/dml.rs:491
Dialect scoping is too broad/inconsistent
major

parse_settings is invoked unconditionally and FORMAT parsing is enabled for GenericDialect as well as ClickHouse, which can change behavior outside intended ClickHouse-only support.

src/parser/mod.rs:12128