chore(cubesql): Upgrade sqlparser to 0.62.0#10983
Conversation
cb3bcef to
bb6caca
Compare
838fce4 to
88776f3
Compare
|
Claude finished @ovr's task in 2m 46s —— View job Claude PR ReviewMechanical sqlparser-0.62 + datafusion-fork-bump migration; structurally clean. Verdict: approve with nits — 4 low-severity findings, all defensive hardening rather than correctness regressions. DetailsChecklist
Inline findings (4 low)
General observations / things I checked and liked
Not covered
|
…fork sqlparser 0.62 parses `INTEGER UNSIGNED` and the `INTn UNSIGNED` aliases into dedicated DataType variants (`IntegerUnsigned`, `Int2/4/8Unsigned`) that our DataFusion fork's `convert_data_type` does not handle, so casts like `CAST(1 AS INTEGER UNSIGNED)` failed planning with "Unsupported SQL type IntegerUnsigned(None)".
After the sqlparser/datafusion 0.62 upgrade, the SQL API crashed with a stack overflow while planning queries with deeply nested plans (a CTE referenced by several CROSS JOINs). The faulting frame was the recursive `plan_normalize`. `plan_normalize` is the recursive entry point, so its stack frame is paid on every level of recursion, and a Rust function frame is sized for its largest `match` arm. A deep plan that only traverses light arms (chains of `CrossJoin`/`Filter`) still paid for the heaviest arm (`Aggregate`, `Join`) at every level. Pull every non-trivial arm into its own `#[inline(never)]` helper and keep `plan_normalize` a thin dispatcher, so each recursion level only pays for the arm it actually goes through. Mirrors the approach used for `generate_sql_for_expr` in the DF wrapper (#10981). Per-level recursive frame, read from the function prologue stack allocation (debug / `opt-level=0`, aarch64).
88776f3 to
c05bb80
Compare
|
Claude finished @ovr's task in 39s —— View job Claude PR Review (re-run on latest)Re-reviewed at Verdict: approve with nits — no new findings. DetailsChecklist
Re-affirmed prior threads (still unresolved, still applicable)
Notes on the new commits
Not covered
|
|
Claude finished @ovr's task in 37s —— View job Claude PR Review (re-run on
|
Return a user-facing error when a ParenthesizedAssignments SET has a mismatched number of variables and values instead of silently dropping the tail via zip.
|
Claude finished @ovr's task in 34s —— View job Claude PR Review (re-run on
|
Fail loudly on non-identifier ObjectNamePart in temp table create/drop instead of falling back to to_string() (which would render a function-style part as the table key and risk asymmetric keys between create and drop).
|
Claude finished @ovr's task in 42s —— View job Claude PR Review (re-run on
|
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## master #10983 +/- ##
==========================================
+ Coverage 78.81% 83.27% +4.45%
==========================================
Files 470 254 -216
Lines 93438 76836 -16602
Branches 3466 0 -3466
==========================================
- Hits 73643 63982 -9661
+ Misses 19292 12854 -6438
+ Partials 503 0 -503
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Claude finished @ovr's task in 24s —— View job Claude PR Review — PR already mergedThis PR was merged as Summary of prior review passesAll four inline findings from the initial review were either addressed or withdrawn before merge:
Verdict at merge: approve — no outstanding findings. |
No description provided.