You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After this fix, issue reported here is still happening.
I understand it happens because on the environment described on previous issue, the alias for model finance__subscriptions is subscriptions and the name for source('stripe','subscriptions') is also subscriptions.
On file _exposures, on line 79 it will search for alias and then fallback to name.
models = self.manifest.read_models()
ctx = self.__Context(
model_refs={m.alias.lower(): m.ref for m in models if m.ref},
table_names={t["id"]: t["name"] for t in self.metabase.get_tables()},
)
In this situation we have two elements with same key subscriptions. I believe it returns the last processed model on model_refs and updates the key with its last value. So, on ctx.model_refs we have something like:
After this fix, issue reported here is still happening.
I understand it happens because on the environment described on previous issue, the alias for model
finance__subscriptions
issubscriptions
and the name forsource('stripe','subscriptions')
is also subscriptions.On file
_exposures
, on line 79 it will search for alias and then fallback to name.In this situation we have two elements with same key subscriptions. I believe it returns the last processed model on model_refs and updates the key with its last value. So, on ctx.model_refs we have something like:
There are two entries (due to 2 with same
subscriptions
key) instead of three for the three existent models.Actual Behavior
When run dbt-metabase exposures, exposures.yml generated has content, with depends_on =
source('stripe', 'subscriptions')
:Expected Behavior
We expect the dependency for
Finance Subscriptions
dashboard to beref('stg_stripe__subscriptions')
:P.S. I had tried this change on parsing by alias before without success.
The text was updated successfully, but these errors were encountered: