AmbiguousTimeError related to a specific datetime (2020-11-01)

Viewed 432

This is coming up in the context of a django project. All datetime objects are tz aware. One day the production server crashed with the follow error:

pytz.exceptions.AmbiguousTimeError: 2020-11-01 01:00:00

The strange thing is that if I change this date manually in the database to almost anything else, the error goes away. Also, if I copy the problematic date into any other datetime field in the database, the same exception is thrown.

I have also tried to add this datetime to other records, and the same problem occurs with those records. Same applied to test and dev databases.

Any ideas?

I am using a mysql database.

UPDATE: seems like this is an issue related to the daylight savings switchover.

0 Answers
Related