dbt-labs/dbt-core · error
Dremio
Error message
Dremio
What it means
This is a Rust `todo!()` panic from `create_static_relation` in crates/dbt-adapter/src/relation/factory.rs:30. The `Dremio` match arm is an unimplemented placeholder, so calls resolving to `AdapterType::Dremio` panic with the message 'Dremio'. It marks Dremio static relation creation as not yet ported in the Rust adapter.
Source
Thrown at crates/dbt-adapter/src/relation/factory.rs:30
/// To be used as api.Relation in the Jinja environment
pub fn create_static_relation(
adapter_type: AdapterType,
quoting: ResolvedQuoting,
) -> Option<Value> {
use AdapterType::*;
let result = match adapter_type {
Snowflake | Databricks | Spark | Fabric | DuckDB | LakeCompute | Exasol | Postgres
| Redshift | Salesforce | Bigquery | ClickHouse => {
let relation_type = RelationStatic {
adapter_type,
quoting,
};
StaticBaseRelationObject::new(Arc::new(relation_type))
}
Starburst => todo!("Starburst"),
Athena => todo!("Athena"),
Trino => todo!("Trino"),
Dremio => todo!("Dremio"),
Oracle => todo!("Oracle"),
Datafusion => todo!("Datafusion"),
};
Some(Value::from_object(result))
}
View on GitHub (pinned to 0267ce9170)
Solutions
- Implement the `Dremio` arm in `create_static_relation`, constructing the Dremio-specific `RelationStatic`/`StaticBaseRelationObject`
- Check `adapter_type` at call sites and surface an unsupported-adapter error rather than reaching the placeholder
- Restrict static relation factory usage to adapters with implemented arms
Example fix
// before
Dremio => todo!("Dremio"),
// after
Dremio => {
let relation_type = RelationStatic { adapter_type, quoting };
StaticBaseRelationObject::new(Arc::new(relation_type))
} Defensive patterns
Strategy: validation
Validate before calling
if matches!(adapter_type, AdapterType::Dremio) {
return Err("create_static_relation is not implemented for Dremio".into());
} Type guard
fn static_relation_supported(t: AdapterType) -> bool {
!matches!(t, AdapterType::Dremio | AdapterType::Starburst | AdapterType::Athena | AdapterType::Trino | AdapterType::Oracle | AdapterType::Datafusion)
} Try / catch
match std::panic::catch_unwind(|| create_static_relation(adapter_type)) {
Ok(v) => v,
Err(_) => return Err("create_static_relation unimplemented for Dremio"),
} Prevention
- Verify Dremio support exists in the relation factory before using jinja relation creation on a Dremio profile
- Return typed errors from new match arms rather than todo!()
- Keep an adapter-support matrix in CI covering every AdapterType variant
When it happens
Trigger: Calling `create_static_relation` (directly, via `get_value`/`adapter_api_value`, or via the static-relation quote-policy tests) with `adapter_type == AdapterType::Dremio`.
Common situations: A dbt run with a Dremio profile whose jinja calls the relation factory; a developer enumerating all AdapterType variants in a test; integrating a new Dremio adapter before filling in the factory match arm.
Related errors
AI-assisted analysis of dbt-labs/dbt-core@0267ce9170 (2026-09-07).
Data as JSON: /api/errors/8bbbbcfe8d11710a.
Report an issue: GitHub.