[Bug 2101044] [NEW] Please migrate from pytz to zoneinfo or dateutil.tz
Benjamin Drung
2101044 at bugs.launchpad.net
Thu Mar 6 09:54:47 UTC 2025
Public bug reported:
pytz has served the Python community well for many years, but it is no
longer the best option for providing time zones. pytz has a non-standard
interface that is very easy to misuse (see
https://blog.ganssle.io/articles/2018/03/pytz-fastest-footgun.html);
this interface was necessary when pytz was created, because datetime had
no way to represent ambiguous datetimes, but this was solved in Python
3.6, which added a fold attribute to datetimes in PEP 495. With the
addition of the zoneinfo module in Python 3.9 (PEP 615), there has never
been a better time to migrate away from pytz.
** Affects: python-croniter (Ubuntu)
Importance: Undecided
Status: New
** Affects: python-django (Debian)
Importance: Unknown
Status: Unknown
** Bug watch added: Debian Bug tracker #1099601
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1099601
** Also affects: python-django (Debian) via
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1099601
Importance: Unknown
Status: Unknown
--
You received this bug notification because you are a member of Ubuntu
OpenStack, which is subscribed to python-croniter in Ubuntu.
https://bugs.launchpad.net/bugs/2101044
Title:
Please migrate from pytz to zoneinfo or dateutil.tz
Status in python-croniter package in Ubuntu:
New
Status in python-django package in Debian:
Unknown
Bug description:
pytz has served the Python community well for many years, but it is no
longer the best option for providing time zones. pytz has a non-
standard interface that is very easy to misuse (see
https://blog.ganssle.io/articles/2018/03/pytz-fastest-footgun.html);
this interface was necessary when pytz was created, because datetime
had no way to represent ambiguous datetimes, but this was solved in
Python 3.6, which added a fold attribute to datetimes in PEP 495. With
the addition of the zoneinfo module in Python 3.9 (PEP 615), there has
never been a better time to migrate away from pytz.
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/python-croniter/+bug/2101044/+subscriptions
More information about the Ubuntu-openstack-bugs
mailing list