jlhitzeman commented on code in PR #53:
URL: https://github.com/apache/flagon-distill/pull/53#discussion_r1682466015


##########
distill/core/log.py:
##########
@@ -57,4 +58,37 @@ def to_json(self) -> str:
 
     def to_dict(self) -> JsonDict:
         return self.data.model_dump(by_alias=True)
-
+    
+    def __lt__(self, other):
+        if isinstance(other, Log):
+            return self.id < other.id
+        if isinstance(other, datetime):
+            return self.id.get_datetime() < other.now()

Review Comment:
   I found that Ryan's comparison works, while trying to compare get_datetime() 
to timestamp() gives an error due to the float return value of timestamp.



-- 
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: notifications-unsubscr...@flagon.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscr...@flagon.apache.org
For additional commands, e-mail: notifications-h...@flagon.apache.org

Reply via email to