turbaszek commented on a change in pull request #12126:
URL: https://github.com/apache/airflow/pull/12126#discussion_r521673165



##########
File path: airflow/operators/dagrun_operator.py
##########
@@ -126,3 +144,22 @@ def execute(self, context: Dict):
                 dag.clear(start_date=self.execution_date, 
end_date=self.execution_date)
             else:
                 raise e
+
+        if self.wait_for_completion:
+            # wait for dag to complete
+            while True:

Review comment:
       @XD-DENG I agree, that's something we can do either here or in follow up 
PR fixing also the `ExternalTaskSensor` which also uses similar infinite loop 
(https://github.com/apache/airflow/pull/12126#discussion_r521662517). 
   
   Personally I would be in favour of timeout. And probably something like `60 
* 60 * 24` similar to what we have in `BaseSensor` to handle most of DAGs




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to