-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Description
Brazil's Daylight Savings Time was aborted by the president last year, but mono is still considering it as active. The DST would start at 2019-11-03T00:00 (03 Nov) and would end at 2020-02-16T00:00 (16 Feb) - local times.
Steps to Reproduce
- Configure an Android phone setting the time zone to Brasília (GMT-03:00), Brazil (or São Paulo GMT-03:00 - Brazil);
- Set a date between 2019-11-03 and 2020-02-15 (inclusive).
- Run an app that prints the time returned by
DateTime.Now. - Compare the printed time to the device's time.
Please check if the system is considering (or not) the DST after changing its datetime settings. The DST should not be active and the displayed offset should be equal to -03:00.
(Also, Android's Java.Util.Date returns the correct time, you can use it to compare the dates).
Current Behavior
The time returned by DateTime.Now is one hour after the system time, and the UTC offset is -02:00 instead of -03:00.
Expected Behavior
The time returned by DateTime.Now should be equal to the system time, and the UTC offset should be -03:00 (the DST is supposed to not be active).
On which platforms did you notice this
[ ] macOS
[ ] Linux
[ ] Windows
[ ] iOS
[X] Android
Version Used:
Mono 6.6.0.155
Xamarin Android 10.1.1.0