Skip to content

Conversation

toriwei
Copy link
Contributor

@toriwei toriwei commented Sep 18, 2025

dbt ignores cluster_by for ephemeral materializations, updating to match that behavior.

@toriwei toriwei requested a review from a team September 18, 2025 18:18
Copy link
Contributor

@themisvaltinos themisvaltinos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm! one nit though not important. and thinking in the warning message referring to it as ephemeral rather than embedded to avoid confusion for the dbt users, though should be fine either way

"Ignoring cluster_by config for model '%s'; cluster_by is not supported for views.",
self.name,
)
elif isinstance(kind, EmbeddedKind):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: maybe combine with above to avoid code duplication. so something like:

if isinstance(kind, (ViewKind, EmbeddedKind)):
  logger.warning(
    "Ignoring cluster_by config for model '%s'; cluster_by is not supported for %s.",
     self.name,
     "views" if isinstance(kind, ViewKind) else "embedded models",
)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will update with this fix + changing warning message to ephemeral. thanks for catching!

@toriwei toriwei force-pushed the tori/fix-modelconfig-clusterby-embedded branch from 4d793f8 to 5b68949 Compare September 18, 2025 21:13
@toriwei toriwei merged commit 88a3679 into main Sep 18, 2025
36 checks passed
@toriwei toriwei deleted the tori/fix-modelconfig-clusterby-embedded branch September 18, 2025 21:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants