On Freitag, 16. Jänner 2026 16:43:50 Mitteleuropäische Normalzeit Ron (Subsurface) via subsurface wrote: > On 2026-01-16 22:22, Berthold Stoeger via subsurface wrote: > > > The crucial question to answer then is: If the time-offset field is > > set, is > > the time of the dive given as local time or with respect to GMT+0? > > Intuitively, I would think the former. > > > The usual best practice is to store and manipulate the time in the > backend > as UTC, which has no political discontinuities other than things like > leap > seconds (which we also don't need to worry about in our code), and makes > relative time math easy (if there's 2 hours difference, things happened > two hours apart regardless of what local clocks said during that > period).
How it's stored is a minor implementation detail once everything is accessed by accessor functions. However, I would generally gravitate to treat everything in local time by default (for example in the filter and statistics) and only do relative to UTC when calculating time differentials (notably N2 loading). As another example, when editing the "offset to UTC", I would keep the local time as is, not reinterpret it. Berthold _______________________________________________ subsurface mailing list -- [email protected] To unsubscribe send an email to [email protected]
