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
I have searched the existing issues, and I could not find an existing issue for this bug
Current Behavior
We have experienced that very rarely, and seemingly randomly, dbt parse or any other dbt command would generate a manifest looking where the alias defined for the model is ignored. This wouldn't impact all models, only a very limited number (often only one).
This would also impact all other dbt commands: dbt run would generate a table using the name instead of the alias. If we try to run a downstream model without rerunning the impacted model, it would fail because the reference would resolve with the wrong table name.
We found no way to trigger/reproduce this bug, but when it happened, we are able to reliably observe it by "re-using" the problematic partial_parse.msgpack file. This happens quite rarely: we observe it about every other week across a team of 5 developers each running multiple local environments and across 4 development/production environment running Airflow/Cosmos.
Expected Behavior
Using the example above, I would expect the manifest to look like:
I can't provide complete reproduction steps as I have not found a way to trigger the bug yet, but once it has happened, I ran the following testing steps, assuming target/bug contains a failing partial_parse.msgpack and target/ok contains a working partial_parse.msgpack:
Run both dbt parse --target-path target/ok and dbt parse --target-path target/bug
Confirm that both target/bug/manifest.json and target/ok/manifest.json have been updated (based on metadata.generated_at), but bug is incorrect (config.alias is null) while ok is as expected.
Run mv target/bug/partial_parse.msgpack target/bug/partial_parse.msgpack.bug, and then again dbt parse --target-path target/bug
Confirm that target/bug/manifest.json has been updated and is now as expected.
Run rm target/bug/partial_parse.msgpack, mv target/bug/partial_parse.msgpack.bug target/bug/partial_parse.msgpack and dbt parse --target-path target/bug
Confirm that target/bug/manifest.json has been updated again and that the error has reappeared.
Is this a new bug in dbt-core?
Current Behavior
We have experienced that very rarely, and seemingly randomly,
dbt parse
or any other dbt command would generate a manifest looking where the alias defined for the model is ignored. This wouldn't impact all models, only a very limited number (often only one).For example, with a model like this one:
The manifest would look like this:
This would also impact all other dbt commands:
dbt run
would generate a table using the name instead of the alias. If we try to run a downstream model without rerunning the impacted model, it would fail because the reference would resolve with the wrong table name.We found no way to trigger/reproduce this bug, but when it happened, we are able to reliably observe it by "re-using" the problematic
partial_parse.msgpack
file. This happens quite rarely: we observe it about every other week across a team of 5 developers each running multiple local environments and across 4 development/production environment running Airflow/Cosmos.Expected Behavior
Using the example above, I would expect the manifest to look like:
Steps To Reproduce
I can't provide complete reproduction steps as I have not found a way to trigger the bug yet, but once it has happened, I ran the following testing steps, assuming
target/bug
contains a failingpartial_parse.msgpack
andtarget/ok
contains a workingpartial_parse.msgpack
:dbt parse --target-path target/ok
anddbt parse --target-path target/bug
target/bug/manifest.json
andtarget/ok/manifest.json
have been updated (based onmetadata.generated_at
), butbug
is incorrect (config.alias
is null) whileok
is as expected.mv target/bug/partial_parse.msgpack target/bug/partial_parse.msgpack.bug
, and then againdbt parse --target-path target/bug
target/bug/manifest.json
has been updated and is now as expected.rm target/bug/partial_parse.msgpack
,mv target/bug/partial_parse.msgpack.bug target/bug/partial_parse.msgpack
anddbt parse --target-path target/bug
target/bug/manifest.json
has been updated again and that the error has reappeared.Relevant log output
Environment
Which database adapter are you using with dbt?
other (mention it in "Additional Context"), spark
Additional Context
Adapter: dbt-databricks 1.8.7
The text was updated successfully, but these errors were encountered: