1

I'm speccing an application that displays time periods to the user. The goal is to present periods in a simple view (no time, no timezones) and detailed view (date and time, with timezone data). The simple view should be unambiguous, in other words the user can glance at it and their assumptions about what they see are correct (they are valid in the local timezone).

For the end of the global period, displaying the date in the AoE timezone [1] will solve this problem. For example, a submission deadline might display as 2018-04-03 (actually 2018-04-03 23:59:59 AoE). This means submissions are accepted as long as it is April 3 somewhere on the planet.

But I also want to indicate that start of a global period. For example, if submissions open on April 2 2018 00:01, they are accepted as soon as it is April 2 somewhere on the planet. (This would currently be at UTC+14, matching the Line Islands.)

I can't see a way to use AoE to derive a global start time. Is there an equivalent to AoE (a standardized semantic timezone) that tracks the global start time?

Notes:

  • Hardcoding UTC-12 and UTC+14 is the simple answer for the modern day. But I'm looking for semantic timezones that would be updated if the values changed (and not reference non-existent historical datetimes).
  • I thought I'd seen Etc/AoE in the tz database but this is not the case.

References:

[1] The Anywhere on Earth (AoE) timezone represents the moment a datetime expires "anywhere on Earth". It currently matches time at Howland Island (UTC-12). If a UTC-13 timezone were invented, it would be updated to track that.

lofidevops
  • 15,528
  • 14
  • 79
  • 119
  • It's an interesting question, but could you please edit it to align with [things that are on-topic for StackOverflow](https://stackoverflow.com/help/on-topic)? Perhaps put it in terms of what you are doing in your application, specific code, tzdb identifiers, etc. Also, be clear what you mean by "track". As currently written, it sounds like human semantics, not a programming topic. – Matt Johnson-Pint Mar 07 '18 at 17:53
  • @MattJohnson I've provided some context, and realised that AoE itself is not in the tzdb like I thought it was, if this is still not programmy enough (looking for a standard measure) I'm happy to migrate to ... Geography Stack Exchange? – lofidevops Mar 08 '18 at 10:32

1 Answers1

1

As far as I could understand, AoE is not a timezone as defined by IANA (AFAIK, a list of all offsets from some geographic region during history).

It's more like a "concept", an idea of a specific date being valid in any place on earth. As you said, this notion of "being valid" will change if more timezones are created or removed.

I don't even know if date/time API's can properly handle AoE automatically - maybe I should study more. But my conclusion is that the only way to achieve your goal is to check manually:

  • you could check all available timezones and see if the date is valid there, comparing to the current date/time at that zone
  • you could configure the UTC+14 as the offset to be compared, and make some scheduled job (daily/weekly/every-time-IANA-publishes-a-new-version?) to check all zones and set the correct one (with the biggest offset?). You must also take care if this zone has Daylight Saving changes, because the offset will change as well (and what to do with overlaps, when clocks shift 1 hour back and a local time may exist twice?)
pandd
  • 103
  • 4