hussein-awala commented on code in PR #34585:
URL: https://github.com/apache/airflow/pull/34585#discussion_r1335250205


##########
airflow/models/dag.py:
##########
@@ -2752,8 +2753,18 @@ def add_logger_if_needed(ti: TaskInstance):
         # for task readiness and dependency management. This is notably faster
         # than creating a BackfillJob and allows us to surface logs to the user
         while dr.state == DagRunState.RUNNING:
+            session.expire_all()

Review Comment:
   I think it's to force sqlalchemy to fetch the new state of all the objects 
from the DB (force refresh).



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to