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
When calling calling a macro passed to a jinja filter, the unit tests will fail, while the model can be compiled and run correctly.
Removing the jinja filter fixes the issue.
Creating a new macro to apply the jinja filter also works.
Expected Behavior
Using a macro with a jinja filter would not cause the unit test to fail.
Compilation Error in unit_test my_unit_test (<path>)
'my_macro' is undefined. This can happen when calling a macro that does not exist. Check for typos and/or install package dependencies with "dbt deps".
I'm facing a similar issue whenever I try to run a dbt model that refers to another macro. The model can build correctly however the unit test would always fail. If I remove the macro then the unit test works.
Is this a new bug in dbt-core?
Current Behavior
When calling calling a macro passed to a jinja filter, the unit tests will fail, while the model can be compiled and run correctly.
Removing the jinja filter fixes the issue.
Creating a new macro to apply the jinja filter also works.
Expected Behavior
Using a macro with a jinja filter would not cause the unit test to fail.
Steps To Reproduce
my_macro.sql
my_model.sql
unit_test.sql
Error message:
Relevant log output
No response
Environment
No response
Which database adapter are you using with dbt?
No response
Additional Context
Work around:
Wrap the jinja filter in another macro.
indent.sql
Then update my_model.sql
The text was updated successfully, but these errors were encountered: