I am a software developer, and I am testing a DateTime converter right now. I need to see if the conversion works when a timezone is transitioning from daylight saving time to its standard time at the last possible timeframe in the transition day, i. e 23:00 to 00:00 happens twice, the former with DST on, and the latter with ST on. Is there ever such an occurrence in the future or past? Is there such a dataset I can query this specifically?
1 Answer
$\begingroup$
$\endgroup$
Per Wikipedia, several countries switch to daylight savings time at midnight. Time jumps from midnight to 1:00 AM in these countries on the date of the switch to daylight savings time. Only Chile, Iran, Lebanon, Palestine, Paraguay, and Syria switch back to standard time at midnight. Time jumps from midnight to 11:00 PM in these countries on the date of the switch from daylight savings time to standard time.
DateTime
, which makes us think .NET - if so, this is a complete aside, but consider using a library like NodaTime or JodaTime (if Java). It's almost certain to have thought of and covered far more corner-cases than your home-rolled solution will have. If you really care about accurate time management across many time zones and many countries, you really can't beat a library (unless this component development is purely an academic exercise you're taking on for its own merits). $\endgroup$