uranusjr commented on code in PR #30076:
URL: https://github.com/apache/airflow/pull/30076#discussion_r1134994821


##########
airflow/dag_processing/manager.py:
##########
@@ -959,7 +973,15 @@ def set_file_paths(self, new_file_paths):
         :return: None
         """
         self._file_paths = new_file_paths
+
+        # clean up the queues; remove anything queued which no longer in the 
list, including callbacks
         self._file_path_queue = collections.deque(x for x in 
self._file_path_queue if x in new_file_paths)
+        Stats.gauge("dag_processing.file_path_queue_size", 
len(self._file_path_queue))
+
+        callback_paths_to_del = list(x for x in 
self._callback_to_execute.keys() if x not in new_file_paths)

Review Comment:
   ```suggestion
           callback_paths_to_del = [x for x in self._callback_to_execute if x 
not in new_file_paths]
   ```



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