#16745: Different times on fields with auto_now and auto_now_add -------------------------------------+------------------------------------- Reporter: kantntreiber@… | Owner: Type: Bug | michaelmior Component: Database layer | Status: new (models, ORM) | Version: 1.3 Severity: Normal | Resolution: Keywords: auto_now, | Triage Stage: Accepted auto_now_add, DateTimeField, | Needs documentation: 1 DateField, field | Patch needs improvement: 1 Has patch: 1 | UI/UX: 0 Needs tests: 0 | Easy pickings: 0 | -------------------------------------+------------------------------------- Changes (by michaelmior):
* cc: michaelmior (added) * needs_better_patch: 0 => 1 * has_patch: 0 => 1 * owner: nobody => michaelmior * needs_docs: 0 => 1 Comment: Apologies for the poorly named initial patch attachment. (Can't seem to delete.) This is my first time attempting a contribution to Django. I attached a patch which is working for me. However, I'm not quite sure how this interacts with the newly-introduced timezone-aware times. I noticed for DateField and TimeField, the current date/time is derived from datetime (i.e. {{{datetime.date.today()}}} or {{{datetime.datetime.now().time()}}}), but for DateTimeField, the time comes from {{{timezone.now()}}}. Is this a bug also, or is there a reason for this I'm not aware of. Anyway, the patch likely needs some work since I'm not too familiar with the Django core, but I'm happy to help :) -- Ticket URL: <https://code.djangoproject.com/ticket/16745#comment:2> Django <https://code.djangoproject.com/> The Web framework for perfectionists with deadlines. -- You received this message because you are subscribed to the Google Groups "Django updates" group. To post to this group, send email to django-updates@googlegroups.com. To unsubscribe from this group, send email to django-updates+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-updates?hl=en.