Michel Lalancette
08/14/2026, 9:29 PMMarvin
08/14/2026, 9:30 PMMarvin
08/14/2026, 9:32 PMprefect-dbt against dbt-core v2.
What I found in the integration code is:
* PrefectDbtRunner uses dbt’s programmatic runner (dbt.cli.main.dbtRunner) rather than shelling out through a brittle custom wrapper.
* It also relies on dbt artifacts like manifest.json / run_results.json, plus some dbt Python-side result/event/manifest classes.
* That means core run/build/test flows are likely to keep working if dbt preserves the public runner + artifact contracts, but there is some risk around internal event/model imports if dbt v2 changes those for the Rust engine.
So my practical expectation is:
* Most likely safe: invoking dbt commands through PrefectDbtRunner
* Less certain: logging/event handling and any code paths that depend on dbt internal Python contracts
* More likely to need Prefect updates: if dbt v2 significantly reshapes the Python API around the Rust engine
What you may need to do on your side
1. Pin versions at first
Don’t auto-upgrade to dbt-core v2 in production immediately.
2. Test a representative flow
Validate:
* dbt parse
* dbt run / dbt build
* artifact generation
* any behavior you rely on from Prefect logs / node-level metadata
3. Watch prefect-dbt release notes / repo
Prefect will likely need to confirm compatibility explicitly once dbt-core v2 is out.
4. Be prepared for a small dependency bump
If there are breaking dbt Python API changes, the likely fix is a prefect-dbt update rather than a major redesign of your flows.
Net answer
Will PrefectDbtRunner keep working?
Likely yes for standard execution paths, but not something I’d assume without version-specific validation once dbt-core v2 is released.
Will there be steps on your side?
Probably just version pinning and testing first, unless dbt v2 introduces a breaking Python API change that requires upgrading prefect-dbt.
I wasn’t able to find an official Prefect compatibility statement for dbt-core v2 yet, so I’d treat this as a code-based assessment rather than a published guarantee.
If you want, I can also dig into:
* the exact prefect-dbt code paths PrefectDbtRunner uses, or
* whether there are already GitHub issues/discussions tracking dbt v2 compatibility.