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
When compiling the log function is called when it should be skipped. This causes an extra log entry to be created when compiling any model that might call the stage_external_tables macro. There aren't any sources available during compile time. The macro shouldn't log that. It is expected.
Steps to reproduce
Add the stage_external_tables macro to a pre-hook, analysis, or other file that will cause an execution during compile time.
Expected results
No log entries should be written during compile.
Actual results
A log entry is created for each time the macro is referenced in a file.
Which database are you using dbt with?
redshift
snowflake
other (specify: BigQuery)
The output of dbt --version:
Core:
- installed: 1.8.4
- latest: 1.8.4 - Up to date!
Plugins:
- bigquery: 1.8.2 - Up to date!
The operating system you're using:
macOs 14.5
The output of python --version:
Python 3.11.9
Additional context
I believe that we can change line 36 in the stage_external_tables to fix the issue.
Existing code
{%ifsources_to_stage|length == 0 %}
Proposed change
{%ifsources_to_stage|length == 0 andexecute%}
The text was updated successfully, but these errors were encountered:
Describe the bug
When compiling the log function is called when it should be skipped. This causes an extra log entry to be created when compiling any model that might call the stage_external_tables macro. There aren't any sources available during compile time. The macro shouldn't log that. It is expected.
Steps to reproduce
Add the stage_external_tables macro to a pre-hook, analysis, or other file that will cause an execution during compile time.
Expected results
No log entries should be written during compile.
Actual results
A log entry is created for each time the macro is referenced in a file.
Which database are you using dbt with?
The output of
dbt --version
:The operating system you're using:
The output of
python --version
:Additional context
I believe that we can change line 36 in the stage_external_tables to fix the issue.
Existing code
Proposed change
The text was updated successfully, but these errors were encountered: