-
Notifications
You must be signed in to change notification settings - Fork 4.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Exception on Linux when using the time zone "America/Buenos_Aires" #103864
Comments
Tagging subscribers to this area: @dotnet/area-system-datetime |
Adding some info for whoever triages. Using 8.0.6 on Ubuntu 22.04.3 the code above succeeds for me. In case it's relevant
what is the similar output for you? |
also please share exception/callstack. |
And please share Ubuntu version/bitness |
Below is short system (and distro) info.
Stack info:
Trace file: |
Some info about installed tz package yet...
Cache:
|
Going by the list of entries on wikipedia, the "correct" entry is In Ubuntu 22.04 (@danmoseley 's version), this is implemented as a filesystem link: -rw-r--r-- 1 root root 246 Feb 21 04:50 Bogota
-rw-r--r-- 1 root root 2410 Feb 21 04:50 Boise
lrwxrwxrwx 1 root root 22 Feb 21 04:50 Buenos_Aires -> Argentina/Buenos_Aires
-rw-r--r-- 1 root root 2254 Feb 21 04:50 Cambridge_Bay
-rw-r--r-- 1 root root 1444 Feb 21 04:50 Campo_Grande In Ubuntu24.04 (@stalek71 's version), the relevant origin file is entirely missing in the operating system (verified by pulling a docker image): -rw-r--r-- 1 root root 246 May 3 11:27 Bogota
-rw-r--r-- 1 root root 2410 May 3 11:27 Boise
-rw-r--r-- 1 root root 2254 May 3 11:27 Cambridge_Bay
-rw-r--r-- 1 root root 1444 May 3 11:27 Campo_Grande Which would probably make this a package maintainer problem. I'm not sure why the file was removed - there are other backwards-compat links that are present in the files. |
Thanks @Clockwork-Muse. I am closing this issue, it is tzdata packaging issue. It is weird though as I am still seeing https://github.com/eggert/tz/blob/3c39cde86bf36dfab1ceb88a4ab9e11a3ec9c1df/backward#L143 still maintaining the backward mapping. Looks to me the package builder built it excluding |
As mentioned in the "tzdata package split" section on the Ubuntu 24.04 release notes, the tzdata package was split into tzdata, tzdata-icu, and tzdata-legacy. Please install tzdata-legacy if you want the backward compatibility links. |
Description
After deploying a small hobbyist application that displays the times for all time zones available in .NET, the application throws an exception when trying to create a TimeZoneInfo for
America/Buenos_Aires
(as well as for some other time zones).On Windows, this time zone is correctly created with this ID, but on Linux, this time zone is named
America/Argentina/Buenos_Aires
Reproduction Steps
Please just run this code below on Windows and Linux (console app).
I used the latest version of .NET 8 available on Ubuntu (8.0.105) with this one setting in project def file:
<InvariantGlobalization>false</InvariantGlobalization>
Expected behavior
America/Buenos_Aires
is resolved proper way on linux (I used Ubuntu)Actual behavior
Throws an exception
Regression?
No response
Known Workarounds
No response
Configuration
Linux x64, latest .Net 8 SDK, tzdata installed
Other information
No response
The text was updated successfully, but these errors were encountered: