Skip to content

ci: add a manual dbt comparison benchmark workflow - #1187

Merged
kvlonge merged 4 commits into
mainfrom
docs/dbt-benchmarks
Oct 21, 2026
Merged

kvlonge merged 4 commits into
mainfrom
docs/dbt-benchmarks

Conversation

@kvlonge

@kvlonge kvlonge commented Oct 21, 2026

Copy link
Copy Markdown
Contributor

Why

The benchmarks page needs a reproducible SQLBuild vs dbt comparison. Our shared dev machine is too loaded for fair wall times, so the benchmark runs on a GitHub-hosted runner from released PyPI packages.

Changes

  • benchmarks/dbt-compare/: write_dbt_dense.py writes the CI dense project for SQLBuild (DuckDB), a rules-off copy and an equivalent dbt project (same SQL, names, folders, DAG; Jinja macros, unit_tests, data_tests, UDF functions). edit_models.py edits N model bodies. bench.sh times cold, warm, one-model edit and 100-model edit runs per variant over interleaved rounds. summarize.py prints median wall, CPU and peak RSS per cell. correctness.sh runs every tool on clean, missing-ref and missing-column projects. README covers method and what isn't equivalent.
  • Variants: sqb_rules, sqb_norules, sqb_rules_full (reuse and delta off), dbt v2 parse, compile, compile --static-analysis strict, dbt Core parse/compile as reference.
  • .github/workflows/benchmark-dbt.yml: workflow_dispatch only, on ubuntu-24.04 like the dense compile jobs, 300-minute timeout. Inputs pin sqlbuild (default latest), dbt 2.0.9, dbt-core 1.12.6, dbt-duckdb 1.11.0, models, rounds, variants. It uploads results plus summary.md (runner CPU/RAM, versions, correctness and benchmark tables) and writes the summary to the job page.

No product code changes, no raw results.

Verification

  • actionlint on all workflows; release gate check passes.
  • ruff format --check and ruff check on benchmarks/.
  • Smoke run of bench.sh (all eight variants, 100 models, one round) and correctness.sh against the released packages: all runs exit 0 on the clean project. SQLBuild reports reuse and delta compiles where expected. Both seeded errors fail in SQLBuild; only the missing ref fails in dbt default compile.
  • Hygiene scan clean.

@kvlonge
kvlonge enabled auto-merge (squash) October 21, 2026 02:16
@kvlonge
kvlonge merged commit 171a5ac into main Oct 21, 2026
26 checks passed
@kvlonge
kvlonge deleted the docs/dbt-benchmarks branch October 21, 2026 02:34
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