{"record":{"id":"29bc27faf7326c9d","repo":"dbt-labs/dbt-core","slug":"athena-29bc27","errorCode":null,"errorMessage":"Athena","messagePattern":"Athena","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/dbt-adapter/src/metadata/get_relation.rs","lineNumber":84,"sourceCode":"            salesforce_get_relation(adapter, state, ctx, conn, database, schema, identifier)\n        }\n        AdapterType::Spark => {\n            spark_get_relation(adapter, state, ctx, conn, schema, identifier, token)\n        }\n        AdapterType::DuckDB | AdapterType::LakeCompute => duckdb_get_relation(\n            adapter, state, ctx, conn, database, schema, identifier, token,\n        ),\n        AdapterType::Fabric => fabric_get_relation(\n            adapter, state, ctx, conn, database, schema, identifier, token,\n        ),\n        AdapterType::ClickHouse => clickhouse_get_relation(\n            adapter, state, ctx, conn, database, schema, identifier, token,\n        ),\n        AdapterType::Exasol => exasol_get_relation(\n            adapter, state, ctx, conn, database, schema, identifier, token,\n        ),\n        AdapterType::Starburst => todo!(\"Starburst\"),\n        AdapterType::Athena => todo!(\"Athena\"),\n        AdapterType::Trino => todo!(\"Trino\"),\n        AdapterType::Dremio => todo!(\"Dremio\"),\n        AdapterType::Oracle => todo!(\"Oracle\"),\n        AdapterType::Datafusion => todo!(\"Datafusion\"),\n    }\n}\n\n/// Parses an `INFORMATION_SCHEMA.ROUTINES`-shaped result batch into a\n/// [`Relation`].\npub(crate) fn relation_from_routines_batch(\n    adapter: &AdapterImpl,\n    database: &str,\n    schema: &str,\n    identifier: &str,\n    batch: &arrow::record_batch::RecordBatch,\n) -> AdapterResult<Option<Relation>> {\n    if batch.num_rows() == 0 {\n        return Ok(None);","sourceCodeStart":66,"sourceCodeEnd":102,"githubUrl":"https://github.com/dbt-labs/dbt-core/blob/0267ce9170576975b76b64ce856b2e5848e96617/crates/dbt-adapter/src/metadata/get_relation.rs#L66-L102","documentation":"This is a Rust `todo!()` panic: `get_relation` in dbt-adapter has no Athena implementation yet, so any Athena adapter relation lookup hits the `todo!(\"Athena\")` arm and panics. It marks a registered AdapterType whose metadata query is still unwritten, not a query or connectivity failure.","triggerScenarios":"Calling `get_relation` (public) with an Athena adapter; the dispatch at crates/dbt-adapter/src/metadata/get_relation.rs:84 executes `todo!(\"Athena\")`.","commonSituations":"Pointing dbt at AWS Athena before Athena relation-resolution support landed; users configure Athena credentials and a workgroup, then dbt panics the first time it must resolve an existing relation (e.g. checking if a model table exists).","solutions":["Use an adapter type that implements get_relation until Athena support ships","Implement an athena_get_relation function (typically via the Glue Data Catalog or Athena INFORMATION_SCHEMA) and wire it into the match arm","Downgrade/pin to a release where the Athena path is implemented or excluded","Fail fast at adapter setup by validating that the chosen adapter type supports metadata lookups"],"exampleFix":"// before\nAdapterType::Athena => todo!(\"Athena\"),\n// after\nAdapterType::Athena => athena_get_relation(\n    adapter, state, ctx, conn, database, schema, identifier, token,\n),","handlingStrategy":"validation","validationCode":"if matches!(adapter_type, AdapterType::Athena) {\n    return Err(\"Athena get_relation is not implemented in this dbt-adapter version\".into());\n}","typeGuard":"fn athena_supported(t: &AdapterType) -> bool { !matches!(t, AdapterType::Athena) }","tryCatchPattern":"let result = std::panic::catch_unwind(|| get_relation(...));\nmatch result {\n    Ok(r) => r,\n    Err(_) => Err(AdapterError::NotImplemented(\"Athena get_relation\")),\n}","preventionTips":["Pin dbt-adapter versions where your adapter type's metadata APIs are implemented","Validate adapter capabilities during profile validation","Add exhaustive-match tests that stub each AdapterType","Fail at startup with a clear unsupported-adapter message"],"tags":["rust","todo-panic","adapter","unimplemented"],"backgroundTag":"method-not-implemented","analyzedSha":"0267ce9170576975b76b64ce856b2e5848e96617","analyzedAt":"2026-09-07T21:53:39.732Z","contentChangedAt":"2026-09-07T21:53:39.732Z","schemaVersion":2},"datasetVersion":"2026-09-14T16:17:12.679Z"}