OVERTHETOP
OVERTHETOP

Reputation: 89

Airflow dag starting passing "execution_date" of 1 day after start date during catchup

I have an airflow dag which I want to run in catch up mode. I have provided the start date for the airflow dag as (2022,5,7) i.e 7 May 2022. The dag is supposed to run at 2200 every day. It is supposed to trigger a C++ script by passing the "execution_date" variable to the script

However, when I start my dag, during the catchup, the first "execution_date" that is passed by the dag to the script is 20220508 (8 May 2022)

Why is this happening? If the start date of the dag is 7 may, why is it not passing the first execution date as 20220507?

Upvotes: 0

Views: 775

Answers (1)

John G
John G

Reputation: 11

To quote one of the online KB, "The first dag run for DAG will be triggered at start_date + schedule_interval which is the execution_date in fact." - which is exactly what you are seeing,

start_date + schedule_interval

More (for instance) at --> https://www.astronomer.io/events/recaps/trigger-dags-any-schedule/

Upvotes: 1

Related Questions