Airflow DAG task not found after updating adding a task
Solution 1
Looks like a bug of airflow. A temp solution is to delete the task instances from airflow db by
delete from task_instance where dag_id=<dag_name> and task_id=<deleted_task_name>';
This should be simpler and less impactful than the resetdb route which would delete everything including variables and connections set before.
Solution 2
Use terminal and run the below command soon after changing the dag file.
airflow initdb
This worked for me.
user3368526
Updated on June 16, 2022Comments
-
user3368526 almost 2 years
I'm having trouble updating a dag file. Dag still have an old version of my dag file. I added a task but it seems not updated when I check the log and UI (DAG->Code).
I have very simple tasks. I of course checked the dag directory path in
airflow.cfg
and restartedairflow webserver/scheduler
. I have no issue running it (but with the old dag file).