ashb commented on code in PR #27540:
URL: https://github.com/apache/airflow/pull/27540#discussion_r1020086076
##########
tests/utils/test_json.py:
##########
@@ -25,9 +25,26 @@
import pendulum
import pytest
+from airflow.datasets import Dataset
from airflow.utils import json as utils_json
+class Z:
+ def __init__(self, x):
+ self.x = x
+
+ def serialize(self) -> dict:
+ return dict({"x": self.x})
+
+ @staticmethod
+ def deserialize(data: dict):
+ return Z(data["x"])
Review Comment:
I wonder if we should call these `airflow_serialize` etc, to reduce the risk
of these clashing when used with "existing" objects?
--
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]