Acehaidrey commented on a change in pull request #19921:
URL: https://github.com/apache/airflow/pull/19921#discussion_r759950400



##########
File path: airflow/utils/timezone.py
##########
@@ -184,3 +184,36 @@ def coerce_datetime(v: Union[None, dt.datetime, DateTime]) 
-> Optional[DateTime]
     if isinstance(v, DateTime):
         return v
     return pendulum.instance(v)
+
+
+def td_format(td_object: Union[None, dt.timedelta, float]):
+    """
+    Format a timedelta object or float into a readable string for time 
duration.
+    For example timedelta(seconds=3602) would become `1 hour 2 seconds`
+    """

Review comment:
       this is really creative. I did not know about this so thank you :) 




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