ephraimbuddy commented on code in PR #28978:
URL: https://github.com/apache/airflow/pull/28978#discussion_r1073327103


##########
airflow/serialization/serde.py:
##########
@@ -73,18 +71,24 @@ def decode(d: dict[str, str | int | T]) -> tuple:
 
 
 def serialize(o: object, depth: int = 0) -> U | None:
-    """
-    Recursively serializes objects into a primitive. Primitives (int, float, 
int, bool)
-    are returned as is. Tuples and dicts are iterated over, where it is 
assumed that keys
-    for dicts can be represented as str. Values that are not primitives are 
serialized if
-    a serializer is found for them. The order in which serializers are used
-    is 1) a serialize function provided by the object 2) a registered 
serializer in
-    the namespace of airflow.serialization.serializers and 3) an attr or 
dataclass annotations.
-    If a serializer cannot be found a TypeError is raised.
-
-    :param o: object to serialize
-    :param depth: private
-    :return: a primitive
+    """Serialize an object into a represatation consisting only built-in types.

Review Comment:
   ```suggestion
       """Serialize an object into a representation consisting only built-in 
types.
   ```



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