ephraimbuddy commented on code in PR #65680:
URL: https://github.com/apache/airflow/pull/65680#discussion_r3146733117


##########
airflow-core/src/airflow/jobs/triggerer_job_runner.py:
##########
@@ -797,7 +793,27 @@ def update_triggers(self, requested_trigger_ids: set[int]):
                 ):
                     to_create.append(workload)
 
-            self.creating_triggers.extend(to_create)
+        return to_create
+
+    def update_triggers(self, requested_trigger_ids: set[int]):
+        """
+        Request that we update what triggers we're running.
+
+        Works out the differences - ones to add, and ones to remove - then
+        adds them to the dequeues so the subprocess can actually mutate the 
running
+        trigger set.
+        """
+        known_trigger_ids = (
+            self.running_triggers.union(x[0] for x in self.events)
+            .union(self.cancelling_triggers)
+            .union(trigger[0] for trigger in self.failed_triggers)
+            .union(trigger.id for trigger in self.creating_triggers)
+        )

Review Comment:
   Ok. Let's try that



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