Complete the code to set the schedule interval for an Airflow DAG.
dag = DAG('example_dag', schedule_interval=[1])
The schedule_interval defines how often the DAG runs automatically. '@daily' means it runs once every day.
Complete the code to import the scheduling module needed for Airflow DAGs.
from airflow.utils.[1] import utc
The timezone module helps define the correct time zone for scheduling DAGs.
Fix the error in the DAG definition to enable scheduling every hour.
dag = DAG('hourly_dag', schedule_interval=[1])
The correct string for hourly scheduling in Airflow is '@hourly'.
Fill both blanks to create a DAG that runs every 15 minutes and starts on January 1, 2024.
dag = DAG('quarter_hour_dag', schedule_interval=[1], start_date=[2])
The cron expression '*/15 * * * *' schedules the DAG every 15 minutes. The start_date must be a datetime object representing January 1, 2024.
Fill all three blanks to define a DAG with a daily schedule, a start date of March 1, 2024, and catchup disabled.
dag = DAG('daily_dag', schedule_interval=[1], start_date=[2], catchup=[3])
The DAG runs daily starting March 1, 2024. Setting catchup=False disables running past missed schedules.