o-nikolas commented on code in PR #55086:
URL: https://github.com/apache/airflow/pull/55086#discussion_r2319978468


##########
airflow-core/src/airflow/models/dag.py:
##########
@@ -2009,12 +2012,25 @@ def next_dagrun_data_interval(self, value: 
tuple[datetime, datetime] | None) ->
     @property

Review Comment:
   +1



##########
airflow-core/src/airflow/serialization/serialized_objects.py:
##########
@@ -1906,7 +1906,11 @@ def serialize_dag(cls, dag: SdkDag) -> dict:
             serialized_dag["dag_dependencies"] = [x.__dict__ for x in 
sorted(dag_deps)]
             serialized_dag["task_group"] = 
TaskGroupSerialization.serialize_task_group(dag.task_group)
 
-            serialized_dag["deadline"] = 
dag.deadline.serialize_deadline_alert() if dag.deadline else None
+            serialized_dag["deadline"] = (
+                [deadline.serialize_deadline_alert() for deadline in 
dag.deadline]
+                if isinstance(dag.deadline, list)
+                else None
+            )

Review Comment:
   Isn't is possible (as of now, but not after Ramit's suggestion)  for it not 
to be a list, but just a single value? So you'd need a third branch here?



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