Skip to content

Commit

Permalink
Fix dbt execution date
Browse files Browse the repository at this point in the history
  • Loading branch information
sydneynotthecity committed Apr 26, 2023
1 parent cfee699 commit 752c311
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
# Require Horizon team reviews
* @stellar/platform-committers
* @stellar/platform-data-committers
4 changes: 3 additions & 1 deletion dags/stellar_etl_airflow/build_dbt_task.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,11 +80,13 @@ def build_dbt_task(dag, model_name, resource_cfg="default"):
dbt_full_refresh = "--full-refresh"

create_dbt_profile_cmd = create_dbt_profile()

execution_date = "EXECUTION_DATE=" + "{{ ds }}"

command = ["sh", "-c"]
args = [
" ".join(
[create_dbt_profile_cmd, "dbt run --select", model_name, dbt_full_refresh]
[create_dbt_profile_cmd, execution_date, "dbt run --select", model_name, dbt_full_refresh]
)
]
logging.info(f"sh commands to run in pod: {args}")
Expand Down

0 comments on commit 752c311

Please sign in to comment.