Opened 14 years ago

Closed 14 years ago

#13535 closed (duplicate)

E-mail date header should be in the local time zone

Reported by: geofft Owned by: nobody
Component: Core (Mail) Version: 1.1
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Outgoing e-mails should use the time zone of the application instead of hardcoding UTC-0. In addition to generally making more sense for servers outside England, my e-mail client (alpine) happens to display the time in the index view without converting it to local time. Fortunately, using the local time zone is easy:

>>> email.Utils.formatdate()
'Fri, 14 May 2010 06:38:42 -0000'
>>> email.Utils.formatdate(localtime=True)
'Fri, 14 May 2010 02:39:33 -0400'

I've attached a patch to django.core.mail.message to effect this.

Attachments (1)

mail-date-localtime.diff (604 bytes ) - added by geofft 14 years ago.
Call formatdate with localtime=True.

Download all attachments as: .zip

Change History (2)

by geofft, 14 years ago

Attachment: mail-date-localtime.diff added

Call formatdate with localtime=True.

comment:1 by Ramiro Morales, 14 years ago

Resolution: duplicate
Status: newclosed

Duplicate of #12666.

Note: See TracTickets for help on using tickets.
Back to Top