Skip to content

Commit 11fa36d

Browse files
authored
Merge branch 'main' into wj/snowflake-deadlock-client-prefetch
2 parents af4a411 + 6f89d7c commit 11fa36d

File tree

54 files changed

+256
-17
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+256
-17
lines changed
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
kind: Under the Hood
2+
body: Remove `catalog` from `RelationConfig` protocol and update base build_catalog_relation to obtain catalog_name from node config
3+
time: 2025-10-08T16:22:09.164799-04:00
4+
custom:
5+
Author: michelleark
6+
Issue: "1376"

dbt-adapters/src/dbt/adapters/base/impl.py

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@
7979
CatalogIntegrationClient,
8080
CatalogIntegrationConfig,
8181
CatalogRelation,
82+
CATALOG_INTEGRATION_MODEL_CONFIG_NAME,
8283
)
8384
from dbt.adapters.contracts.connection import Credentials
8485
from dbt.adapters.contracts.macros import MacroResolverProtocol
@@ -335,9 +336,18 @@ def get_catalog_integration(self, name: str) -> CatalogIntegration:
335336
return self._catalog_client.get(name)
336337

337338
@available
338-
def build_catalog_relation(self, config: RelationConfig) -> CatalogRelation:
339-
catalog = self.get_catalog_integration(config.catalog)
340-
return catalog.build_relation(config)
339+
def build_catalog_relation(self, config: RelationConfig) -> Optional[CatalogRelation]:
340+
if not config.config:
341+
return None
342+
343+
# "catalog" is legacy, but we support it for backward compatibility
344+
if catalog_name := config.config.get(
345+
CATALOG_INTEGRATION_MODEL_CONFIG_NAME
346+
) or config.config.get("catalog"):
347+
catalog = self.get_catalog_integration(catalog_name)
348+
return catalog.build_relation(config)
349+
350+
return None
341351

342352
###
343353
# Methods to set / access a macro resolver

dbt-adapters/src/dbt/adapters/contracts/relation.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,6 @@ class RelationConfig(Protocol):
6060
tags: List[str]
6161
quoting_dict: Dict[str, bool]
6262
config: Optional[MaterializationConfig]
63-
catalog: Optional[str]
6463

6564

6665
class ComponentName(StrEnum):

dbt-bigquery/.changes/1.11.0-b1.md

Lines changed: 25 additions & 0 deletions

0 commit comments

Comments
 (0)