MongoEngine/mongoengine — pull request #151 by lexqt (2012-10-14 22:25:29+00:00)
Title: Fix Django timezone support

Django 1.4 introduced timezone support. However when it is activated Session backend and User model from mongoengine.django package do not handle dates properly. I add one test as an example (it is passed OK with django 1.3 but not with django 1.4) and necessary fixes.

Useful links:
https://docs.djangoproject.com/en/1.4/topics/i18n/timezones/
http://docs.python.org/library/datetime.html
http://api.mongodb.org/python/current/faq.html#what-is-the-correct-way-to-handle-time-zones-with-pymongo