potiuk commented on code in PR #58993:
URL: https://github.com/apache/airflow/pull/58993#discussion_r2622477416


##########
airflow-core/src/airflow/serialization/definitions/assets.py:
##########
@@ -18,10 +18,292 @@
 
 from __future__ import annotations
 
-from airflow.sdk import AssetWatcher  # TODO: Implement serialized assets.
+import json
+from typing import TYPE_CHECKING, Any, ClassVar, Literal
 
+import attrs
 
-class SerializedAssetWatcher(AssetWatcher):
-    """JSON serializable representation of an asset watcher."""
+from airflow.api_fastapi.execution_api.datamodels.asset import AssetProfile
+from airflow.serialization.dag_dependency import DagDependency
 
+if TYPE_CHECKING:
+    from collections.abc import Callable, Iterable, Iterator, MutableSequence
+
+    from typing_extensions import Self
+
+    from airflow.models.asset import AssetModel
+
+    AttrsInstance = attrs.AttrsInstance
+else:
+    AttrsInstance = object
+
+
[email protected](frozen=True)

Review Comment:
   Again out of curiosity - do we have (I have not seen it but maybe missed it) 
some mechanism to make sure those two parallel definitions are in sync? Did we 
consider the scenario what happens when someone adding a new field or modifying 
it will forge to update the parallell definition?
   
   I know we had a lot of discussion about it in AIP-44 work and there were a 
lot of worries tha those definitions were essentially parallel and not 
DRY--friendly, I just would love to know what was thinking here - to be able to 
better maintain it in the future.



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