dstandish commented on code in PR #41232:
URL: https://github.com/apache/airflow/pull/41232#discussion_r1717799345
##########
airflow/jobs/triggerer_job_runner.py:
##########
@@ -643,7 +648,9 @@ async def run_trigger(self, trigger_id, trigger):
# allow triggers a chance to cleanup, either in that case or if
# they exit cleanly. Exception from cleanup methods are ignored.
with suppress(Exception):
- await trigger.cleanup()
+ trigger_details = self.triggers[trigger_id]
+ if
trigger.should_cleanup(trigger_details["termination_reason"]):
Review Comment:
And that is a very reasonable concern @TakawaAkirayo. However right now
with airflow 3 coming, we have a special opportunity where we can break
backward compatibility. Even in 2.x we could have done it by adding some kind
of compatibility layer / conditional handling. But since this will only make
it into 3.x we don't need that. What we will need to do though, is update
providers to be forward-compatible with this change, so that new provider
releases will be compat with 2.x and 3.x as much as possible. E.g. maybe
changing existing trigger cleanup signatures to take **kwargs.
--
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]