From 95d8c4e4d6e7915af725c242e493f8f28e988a05 Mon Sep 17 00:00:00 2001 From: Colin Powell Date: Fri, 25 Jul 2025 17:33:59 -0400 Subject: [PATCH] [profiles] Clean up timezone stuff --- vrobbler/apps/profiles/admin.py | 1 + vrobbler/apps/profiles/utils.py | 16 ++++++++-------- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/vrobbler/apps/profiles/admin.py b/vrobbler/apps/profiles/admin.py index 67b8784..e38136c 100644 --- a/vrobbler/apps/profiles/admin.py +++ b/vrobbler/apps/profiles/admin.py @@ -7,6 +7,7 @@ from profiles.models import UserProfile class UserProfileAdmin(admin.ModelAdmin): date_hierarchy = "created" ordering = ("-created",) + readonly_fields = ("timezone_change_log",) exclude = ( "twitch_token", "twitch_client_secret", diff --git a/vrobbler/apps/profiles/utils.py b/vrobbler/apps/profiles/utils.py index b7428fc..b933a6a 100644 --- a/vrobbler/apps/profiles/utils.py +++ b/vrobbler/apps/profiles/utils.py @@ -62,20 +62,20 @@ def start_of_year(dt, profile) -> datetime: def one_off_fix_colins_profile(profile): home_tz = "America/New_York" - europe = "2022-10-15" + europe = "2022-10-15 06:00:00" + europe_end = "2023-12-16 12:00:00" europe_tz = "Europe/Paris" - europe_end = "2023-12-15" - washington = "2023-04-28" + washington = "2023-04-28 06:00:00" + washington_end = "2023-05-04 12:00:00" washington_tz = "America/Los_Angeles" - washington_end = "2023-05-04" - camp = "2024-08-04" - camp_end = "2024-08-10" + camp = "2024-08-04 17:00:00" + camp_end = "2024-08-10 12:00:00" camp_tz = "America/Halifax" - summer = "2025-07-09 12:00:00" - summer_end = "2025-07-13 20:30:00" + summer = "2025-07-09 06:00:00" + summer_end = "2025-07-11 23:30:00" summer_tz = "America/Los_Angeles" profile.timezone_change_log = ""