Skip to content

fix: harden SQL analysis for complex projects - #744

Merged
chio-labs-delivery[bot] merged 1 commit into
mainfrom
feat/configurable-sql-analysis-complexity-guard
Sep 19, 2026
Merged

chio-labs-delivery[bot] merged 1 commit into
mainfrom
feat/configurable-sql-analysis-complexity-guard

Conversation

@kvlonge

@kvlonge kvlonge commented Sep 19, 2026

Copy link
Copy Markdown
Contributor

Why

Trusted project SQL can legitimately exceed Polyglot's defensive function-depth default. Test-plan inspection also sent compiler-proven native dynamic pivots back through generic query analysis, which could terminate the process, while documented custom Rule harness files under tests/ were rejected by Python-layout validation.

Changes

  • apply a bounded function-call depth of 512 to SQLBuild-owned Polyglot parsing, validation, transpilation, and query-analysis entry points while preserving explicit caller overrides and every other guard
  • carry the compiler-proven dynamic-pivot input relation into fixture completion instead of reanalyzing adapter-native generated-column SQL
  • allow Python test files under the documented tests/ root
  • add unit and real CLI regressions for deep SQL, dynamic-pivot inspection, and Rule harness layout
  • adopt Polyglot 0.12.0 and its more precise literal/null nullability results

Verification

  • focused unit and CLI tests pass
  • make test passes
  • Ruff, ty, Fensu, and public-repository hygiene checks pass

@chio-labs-delivery
chio-labs-delivery Bot enabled auto-merge (squash) September 19, 2026 02:23
@chio-labs-delivery
chio-labs-delivery Bot merged commit b373c93 into main Sep 19, 2026
18 checks passed
@chio-labs-delivery
chio-labs-delivery Bot deleted the feat/configurable-sql-analysis-complexity-guard branch September 19, 2026 02:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant