mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-08 12:32:43 +00:00
Withings, Fitbit, Google Health, Polar and Oura wrote each daily total and daily summary at noon UTC of its date. From UTC+12 on (New Zealand all year, Fiji, Tonga, Samoa) noon UTC is already the next local day, so every synced step count, SpO2 or resting-pulse day showed up a day late. The rows now sit at local noon of their date in the user's zone, and the fetch windows run through the user's own today. Fitbit weigh-ins carry a local wall clock without an offset and were read as UTC; they are read in the user's zone now. ExternalIds stay on the calendar date, so the next sync finds each row and moves it in place instead of adding a second one, and the day a row leaves is refolded. Rows inside each integration's re-read window heal on the next sync; Fitbit and Google Health re-read the whole history on reconnect.