dbt-labs/dbt-core · error

from_config: Only available for Snowflake and Redshift

Error message

from_config: Only available for Snowflake and Redshift

What it means

`from_config` is only implemented for the Snowflake adapter despite the message also mentioning Redshift; all remaining AdapterType values hit this wildcard arm. The message text is slightly stale but means: this adapter does not support building a relation from a node config.

Source

Thrown at crates/dbt-adapter/src/relation/relation_impl.rs:1081

                                format!("Failed to deserialize InternalDbtNodeWrapper: {e}"),
                            )
                        })?;
                let local_config = match local_config {
                    InternalDbtNodeWrapper::Model(model) => model,
                    _ => {
                        return Err(minijinja::Error::new(
                            minijinja::ErrorKind::InvalidOperation,
                            "Expected a model node",
                        ));
                    }
                };
                let relation_config = SnowflakeConfigRelationType::of(local_config.as_ref())
                    .loader()
                    .from_local_config(local_config.as_ref())?;

                Ok(Value::from_object(relation_config))
            }
            _ => Err(minijinja::Error::new(
                minijinja::ErrorKind::InvalidOperation,
                "from_config: Only available for Snowflake and Redshift",
            )),
        }
    }

    fn normalize_component(&self, component: &str) -> String {
        use AdapterType::*;
        match self.adapter_type {
            Salesforce | Bigquery | ClickHouse => component.to_string(),
            Snowflake => component.to_uppercase(),
            _ => component.to_lowercase(),
        }
    }

    fn render_self_as_str(&self) -> String {
        if self.adapter_type == AdapterType::DuckDB
            && let Some(external) = &self.external

View on GitHub (pinned to 0267ce9170)

Solutions

  1. Run the affected models on Snowflake, or use the default relation construction path (from Parliament/parse-time relation) instead of from_config.
  2. Guard macro code with `adapter.type()` checks and fall back to from_parliament/from_dict for other adapters.
  3. Implement a from_config branch for your adapter in relation_impl.rs if needed.

Example fix

// before
relation = BaseRelation.from_config(config=config)
// after
if adapter.type() == 'snowflake':
    relation = BaseRelation.from_config(config=config)
else:
    relation = BaseRelation.from_parliament(parliament=parliament)
Defensive patterns

Strategy: fallback

Validate before calling

{% if adapter.type() == 'snowflake' %}
  {% set relation = BaseRelation.from_config(config=config) %}
{% else %}
  {% set relation = BaseRelation.from_parliament(parliament=parliament) %}
{% endif %}

Type guard

let can_from_config = matches!(adapter_type, AdapterType::Snowflake);

Try / catch

try:
    relation = BaseRelation.from_config(config=config)
except minijinja.Error as e:
    if 'Only available' in str(e):
        relation = BaseRelation.from_parliament(parliament=parliament)
    else:
        raise

Prevention

When it happens

Trigger: Calling BaseRelation.from_config() while running on any adapter other than Snowflake (the Redshift arm does not exist in this match).

Common situations: Running a project with relation-from-config macros on Postgres/BigQuery/Databricks, or after switching warehouse profiles.

Understand the failure class

Background: UnsupportedOperationException and "is not supported" errors: when a library deliberately refuses a call — this error's family across 30 libraries.

Related errors


AI-assisted analysis of dbt-labs/dbt-core@0267ce9170 (2026-09-07). Data as JSON: /api/errors/a1c1c2ee4977af9b. Report an issue: GitHub.