Skip to content
Snippets Groups Projects
Commit 77515966 authored by Lene Wasskog's avatar Lene Wasskog
Browse files

fix: Localize start time

parent c75b40ab
Branches
Tags
No related merge requests found
...@@ -53,9 +53,9 @@ if year > today.year: ...@@ -53,9 +53,9 @@ if year > today.year:
exit(0) exit(0)
# If we are before the recurring start date, exit nicely # If we are before the recurring start date, exit nicely
start_time = datetime.strptime(f"{year}-{recurring_start_date}","%Y-%m-%d") start_time = local_timezone.localize(datetime.strptime(f"{year}-{recurring_start_date}","%Y-%m-%d"))
if today <= start_time: if today <= start_time:
print(f"Today is before the configured start time of {start_time}. Exiting.") print(f"Today is before the configured model start {start_time}. Exiting.")
exit(0) exit(0)
# """ # """
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment