Our localTimezone() function returns unexpected short form timezone names (e.g. "CET") on some systems. This breaks our tests for localTimezone as well as safeTimezone on those systems.
Seen with Deno 1.39.0 on macOS 14.2
The underlying call is Intl.DateTimeFormat()?.resolvedOptions()?.timeZone
There are no options affecting returned timeZone, so my suggestion is that we rewrite localTimezone to fallback to returning UTC whenever no / can be found in reported timeZone. The short form will not be useful for the UI anyway, for example the short forms will not be available in a dropdown.
Our
localTimezone()function returns unexpected short form timezone names (e.g."CET") on some systems. This breaks our tests forlocalTimezoneas well assafeTimezoneon those systems.Seen with Deno 1.39.0 on macOS 14.2
The underlying call is
Intl.DateTimeFormat()?.resolvedOptions()?.timeZoneThere are no options affecting returned
timeZone, so my suggestion is that we rewritelocalTimezoneto fallback to returningUTCwhenever no/can be found in reportedtimeZone. The short form will not be useful for the UI anyway, for example the short forms will not be available in a dropdown.