From abf46eb3577f335c3b10546a28e1078e67af2f0d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABl=20Honorez?= Date: Sun, 31 Dec 2023 19:27:28 +0100 Subject: [PATCH] fixing missing module in calls --- Post_RSS_on_SubStack.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Post_RSS_on_SubStack.py b/Post_RSS_on_SubStack.py index d035d19..1171d5d 100644 --- a/Post_RSS_on_SubStack.py +++ b/Post_RSS_on_SubStack.py @@ -73,9 +73,9 @@ class SubStackTask: async def run_daily_at_6_am(self): while True: - now = datetime.now() + now = datetime.datetime.now() # Calculate the time until 6 AM next day - next_run = (now + timedelta(days=1)).replace(hour=6, minute=5, second=0, microsecond=0) + next_run = (now + datetime.timedelta(days=1)).replace(hour=6, minute=5, second=0, microsecond=0) sleep_seconds = (next_run - now).total_seconds() # Wait until the next run time