ZoneInfo Module In Python


  • Through the ZoneInfo module Python standard library supports IANA timezone database.
  • The ZoneInfo module has several constants, functions and a ZoneInfo class. All of them together provide the IANA timezone semantics to the developers.
  • Prior to the introduction of ZoneInfo class, the only concrete implementation of the tzinfo abstract class was the TimeZone class.
  • TimeZone class lacks two things.
    •     It is not an implementation that has been designed to support IANA databases.
    •     It does not handle daylight saving times.
  • The ZoneInfo class supports both IANA timezone database as well as the daylight saving times.

Copyright 2022 ©