datetime.datetime.combine(
datetime.date.today(),
datetime.time(),
pytz.timezone('Europe/Amsterdam')
)
Fortunately, the new zoneinfo module is a lot safer to use. #python
datetime.datetime.combine(
datetime.date.today(),
datetime.time(),
pytz.timezone('Europe/Amsterdam')
)
Fortunately, the new zoneinfo module is a lot safer to use. #python
Lesson learned today: don't cache data containing naive local datetime objects, even if that's what the API returns. That cache will break twice a year.
#dst #PythonProgramming
Lesson learned today: don't cache data containing naive local datetime objects, even if that's what the API returns. That cache will break twice a year.
#dst #PythonProgramming