hwang-cadent commented on code in PR #56973:
URL: https://github.com/apache/airflow/pull/56973#discussion_r2850015808


##########
airflow-core/src/airflow/serialization/serialized_objects.py:
##########
@@ -1587,6 +1587,11 @@ def _deserialize_field_value(cls, field_name: str, 
value: Any) -> Any:
         elif field_name == "resources":
             return Resources.from_dict(value) if value is not None else None
         elif field_name.endswith("_date"):
+            # Check if value is ARG_NOT_SET before trying to deserialize as 
datetime

Review Comment:
   No, this change is not directly tested in test_serialized_objects.py. It's 
currently tested indirectly through TriggerDagRunOperator tests, which verify 
the behavior when logical_date is NOTSET.
   A direct unit test for OperatorSerialization._deserialize_field_value() 
handling ARG_NOT_SET for date fields would be clearer and more focused. Should 
I add a direct test in test_serialized_objects.py?



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