dbt_artifacts
dbt_artifacts copied to clipboard
[Bug]: dbt_artifacts.upload_results on on-run-end causing dbt docs generate step error: 'MacroGenerator' object is not iterable
Overview
Our customer has an on-run-end in their dbt_project.yml as follows:
on-run-end:
- "{% if target.name == 'prod' or target.name == 'test' %}{{ dbt_artifacts.upload_results(results) }}{% endif %}"
In their dbt runs, they are getting the following error:
Compilation Error in operation snowflake_edw-on-run-end-0 (./dbt_project.yml)
'MacroGenerator' object is not iterable
> in macro upload_results (macros/upload_results/upload_results.sql)
> called by operation snowflake_edw-on-run-end-0 (./dbt_project.yml)
The issue only started since 16 Sep onwards, prior to this date - the same setup worked as per normal.
How to reproduce
Unfortunately, we have not been able to reproduce this outside of the customer's account/environment.
Expected behaviour
There should not have been any error raised.
Screenshots
Environment
Results of running dbt --version:
1.7.18
Please paste the contents of your packages.yml file here:
packages:
- package: dbt-labs/dbt_external_tables
version: 0.8.1
- package: dbt-labs/dbt_utils
version: 1.0.0
- package: Montreal-Analytics/snowflake_utils
version: 0.5.0
- package: fivetran/fivetran_log
version: [">=1.0.0", "<1.1.0"]
- package: brooklyn-data/dbt_artifacts
version: 2.6.3