hussein-awala commented on PR #31987:
URL: https://github.com/apache/airflow/pull/31987#issuecomment-1668290071

   > Why is run on a trigger not just returning an event instead? That would 
resolve the entire post-yield work discussion since it’s not possible to do 
things after a return in the first place. It seems to me if we do this, we 
should start re-design the trigger interface for 2.8.
   
   I had the same question, but I found the answer in the [deferring 
doc](https://github.com/apache/airflow/blob/main/docs/apache-airflow/authoring-and-scheduling/deferring.rst)
 :
   > Currently Triggers are only used up to their first event, as they are only 
used for resuming deferred tasks (which happens on the first event fired). 
However, we plan to allow DAGs to be launched from triggers in future, which is 
where multi-event triggers will be more useful.
   
   I don't know if this plan is still valid or not, but switching from yield 
event then return to just return event is a good idea. I already tested it when 
I added a return statement after each yield, but I tried to avoid changing the 
design.


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