Complete the code to define a DAG with a daily schedule.
dag = DAG('example_dag', schedule_interval=[1], start_date=datetime(2024, 1, 1))
The schedule_interval set to '@daily' makes the DAG run once every day.
Complete the code to set task dependencies so task2 runs after task1.
task1 >> [1]The >> operator sets the order so task2 runs after task1.
Fix the error in the DAG definition by completing the missing argument.
dag = DAG('my_dag', schedule_interval='@daily', [1]=datetime(2024, 1, 1))
end_date instead of start_date.execution_date.The start_date argument tells Airflow when to start scheduling the DAG.
Fill both blanks to create a task that runs a Python function using the correct operator and DAG.
task = [1](task_id='print_hello', python_callable=print_hello, dag=[2])
BashOperator for Python functions.PythonOperator runs Python functions, and dag is the DAG instance.
Fill all three blanks to create a dictionary comprehension that maps task IDs to their start dates if the start date is after 2024-01-01.
task_start_dates = {task.task_id: task.[1] for task in tasks if task.[2] [3] datetime(2024, 1, 1)}end_date instead of start_date.This comprehension collects start_date of tasks where the start_date is after January 1, 2024.