From f14b0403755b8abcb0ff0c2529a20cad8ba376cd Mon Sep 17 00:00:00 2001 From: Ryan Date: Wed, 19 Nov 2025 20:48:51 -0500 Subject: [PATCH] Adding utils.py file --- utils.py | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 utils.py diff --git a/utils.py b/utils.py new file mode 100644 index 0000000..da517e8 --- /dev/null +++ b/utils.py @@ -0,0 +1,16 @@ +import datetime + + + +def date_to_epoch(date_str: str) -> float: + split_date = date_str.split("-") + date = datetime.datetime( + int(split_date[0]), + int(split_date[1]), + int(split_date[2]), + 0, + 0, + 0, + ) + + return date.timestamp()