-
Type: Bug
-
Resolution: Fixed
-
Priority: Minor - P4
-
Affects Version/s: None
-
Component/s: None
-
None
-
Python Drivers
-
Not Needed
-
When initializing a MotorClient (or getting a DB from the client) with CodecOption and setting the tzinfo (together with tz_aware) this has no effect or even leads to an error. Without this option the user has to manually convert datetimes to his preferred timezone. This option works without any problems in the regular python mongo db driver.
When setting the tzinfo arg on MotorClient, this raises an error because the tzinfo argument is mutable. Fair so far, because tzinfo is not a documented argument, but would be a nice option.
When getting a database from the client (get_database, get_default_database) using CodeOptions as argument is documented, so here it is a real bug. There will be no error raised, but it will just get ignored (even worse than an error imho).
- is related to
-
PYTHON-4691 non-UTC timezones break DATETIME_CLAMP/DATETIME_AUTO
- Closed
-
PYTHON-4690 Add repr support to bson.tz_util.FixedOffset
- Closed