TZ wip, UI model stats fix

This commit is contained in:
Dobromir Popov
2025-07-29 15:12:48 +03:00
parent afde58bc40
commit b3e3a7673f
3 changed files with 171 additions and 143 deletions

View File

@ -1515,9 +1515,9 @@ class DataProvider:
# Ensure gap_start has same timezone as end_time for comparison
if gap_start.tzinfo is None:
gap_start = sofia_tz.localize(gap_start)
elif gap_start.tzinfo != sofia_tz:
gap_start = gap_start.astimezone(sofia_tz)
gap_start = SOFIA_TZ.localize(gap_start)
elif gap_start.tzinfo != SOFIA_TZ:
gap_start = gap_start.astimezone(SOFIA_TZ)
if gap_start < end_time:
# Need to fill gap from cache_end to now