-
Notifications
You must be signed in to change notification settings - Fork 78
Description
Current Behaviour
In testing ex_cldr_dates_times updated time zone formatting I see that the valid timezone "Factory" is not recognised as such by Tz since the factory file is not compiled by Tz:
for filename <-
~w(africa antarctica asia australasia backward etcetera europe northamerica southamerica)s do
I appreciate this is a very niche case, but it is a valid timezone. In fact there is some annotations to that affect in the file.
TLDR; TZ="Factory" is a valid timezone
TZ="Factory" was added to TZDB in 1989, and in 2016 its abbreviation
was changed to "-00" from a longish English-language error message.
Around 2010, CLDR added "Etc/Unknown" for use with TZDB, to stand
for an unknown or invalid time zone. These two notions differ:
TZ="Factory" is a valid timezone, so tzalloc("Factory") succeeds, whereas
TZ="Etc/Unknown" is invalid and tzalloc("Etc/Unknown") fails.
Also, a downstream distributor could modify Factory to be a
default timezone suitable for the devices it manufactures,
whereas that cannot happen for Etc/Unknown.
Expected behaviour
"factory" is a valid time zone.
Possible resolution
Change:
~w(africa antarctica asia australasia backward etcetera europe northamerica southamerica)sTo
~w(africa antarctica asia australasia backward etcetera europe northamerica southamerica factory)s