Re: 002_types.pl fails on some timezones on windows - Mailing list pgsql-hackers

From Tom Lane
Subject Re: 002_types.pl fails on some timezones on windows
Date
Msg-id 3714784.1633207335@sss.pgh.pa.us
Whole thread Raw
In response to Re: 002_types.pl fails on some timezones on windows  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: 002_types.pl fails on some timezones on windows
List pgsql-hackers
I wrote:
> Oh, thanks for the pointer to CLDR!  I tried re-generating our data
> based on theirs, and ended up with the attached draft patch.

Hearing no objections, pushed after another round of review
and a couple more fixes.

For the archives' sake, here are the remaining discrepancies
between our mapping and CLDR's entries for "territory 001",
which I take to be their recommended defaults:

* Our documented decision to map "Central America" to "CST6",
on the grounds that most of Central America doesn't actually
observe DST nowadays.

* Now-documented decision to map "Greenwich Standard Time"
to Europe/London, not Atlantic/Reykjavik as they have it.

* The miscellaneous deltas shown in the attached diff, which in
many cases boil down to "we chose the first name mentioned for the
zone, while CLDR did something else".  I felt that our historical
mappings of these cases weren't wrong enough to justify any
political flak I might take for changing them.  OTOH, maybe we
should just say "we follow CLDR" and be done with it.

            regards, tom lane

--- findtimezone.c    2021-10-02 15:37:17.309929827 -0400
+++ cldr_transformed.c    2021-10-02 14:32:32.359818338 -0400
@@ -888,7 +131,7 @@ static const struct
     {
         /* (UTC+01:00) Belgrade, Bratislava, Budapest, Ljubljana, Prague */
         "Central Europe Standard Time", "Central Europe Daylight Time",
-        "Europe/Belgrade"
+        "Europe/Budapest"
     },
     {
         /* (UTC+01:00) Sarajevo, Skopje, Warsaw, Zagreb */
@@ -898,7 +141,7 @@ static const struct
     {
         /* (UTC+11:00) Solomon Is., New Caledonia */
         "Central Pacific Standard Time", "Central Pacific Daylight Time",
-        "Pacific/Noumea"
+        "Pacific/Guadalcanal"
     },
     {
         /* (UTC-06:00) Central Time (US & Canada) */
@@ -988,7 +226,7 @@ static const struct
     {
         /* (UTC+02:00) Helsinki, Kyiv, Riga, Sofia, Tallinn, Vilnius */
         "FLE Standard Time", "FLE Daylight Time",
-        "Europe/Helsinki"
+        "Europe/Kiev"
     },
     {
         /* (UTC+04:00) Tbilisi */
@@ -1006,7 +244,7 @@ static const struct
     {
         /* (UTC+02:00) Athens, Bucharest */
         "GTB Standard Time", "GTB Daylight Time",
-        "Europe/Athens"
+        "Europe/Bucharest"
     },
     {
         /* (UTC-05:00) Haiti */
@@ -1244,7 +441,7 @@ static const struct
     {
         /* (UTC+01:00) Brussels, Copenhagen, Madrid, Paris */
         "Romance Standard Time", "Romance Daylight Time",
-        "Europe/Brussels"
+        "Europe/Paris"
     },
     {
         /* (UTC+11:00) Chokurdakh */
@@ -1349,7 +491,7 @@ static const struct
     {
         /* (UTC+13:00) Samoa */
         "Samoa Standard Time", "Samoa Daylight Time",
-        "Pacific/Samoa"
+        "Pacific/Apia"
     },
     {
         /* (UTC+00:00) Sao Tome */
@@ -1519,7 +661,7 @@ static const struct
     {
         /* (UTC+01:00) Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna */
         "W. Europe Standard Time", "W. Europe Daylight Time",
-        "CET"
+        "Europe/Berlin"
     },
     {
         /* (UTC+07:00) Hovd */
@@ -1533,7 +675,7 @@ static const struct
     {
         /* (UTC+10:00) Guam, Port Moresby */
         "West Pacific Standard Time", "West Pacific Daylight Time",
-        "Pacific/Guam"
+        "Pacific/Port_Moresby"
     },
     {
         /* (UTC+09:00) Yakutsk */

pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: Adding CI to our tree
Next
From: Tom Lane
Date:
Subject: Re: Adding CI to our tree