GNOME Bugzilla – Bug 714376
Date: header in composed emails has bogus time zone designation
Last modified: 2014-09-03 00:12:20 UTC
---- Reported by jim@yorba.org 2012-08-10 14:30:00 -0700 ---- Original Redmine bug id: 5650 Original URL: http://redmine.yorba.org/issues/5650 Searchable id: yorba-bug-5650 Original author: Jim Nelson Original description: When I send a message to myself from Geary, the resulting email has this for a Date: header: Fri, 10 Aug 2012 21:13:58 **-0007** However, the Date should be (looking at the Received: header) Fri, 10 Aug 2012 14:21:00 **-0700** Note the bogus time zone designation. Also note that the minutes are offset by the bogus value (7 minutes). What's strange is that the time is displayed properly in the conversation viewer. However, the Date: field problem does seem to cause ordering problems when the conversation includes messages from a non-Geary emailer. Related issues: related to geary - 5887: [norepro] Message delivery seems delayed for 24 hours (Invalid) duplicated by geary - 5449: correct handling of timezones (Duplicate) ---- Additional Comments From geary-maint@gnome.bugs 2013-01-15 16:34:00 -0800 ---- ### History #### #1 Updated by Adam Dingle about 1 year ago * **Target version** deleted (<strike>_0.2_</strike>) #### #2 Updated by Jim Nelson 10 months ago * **Category** set to _engine_ * **Priority** changed from _High_ to _Normal_ --- Bug imported by chaz@yorba.org 2013-11-21 20:26 UTC --- This bug was previously known as _bug_ 5650 at http://redmine.yorba.org/show_bug.cgi?id=5650 Unknown version " in product geary. Setting version to "!unspecified". Unknown milestone "unknown in product geary. Setting to default milestone for this product, "---". Setting qa contact to the default for this product. This bug either had no qa contact or an invalid one. Resolution set on an open status. Dropping resolution
I suspect that this bug delays / discards emails sent through Apple iCloud SMTP service too.
In file "rfc822-message.vala", on the row that says: --------------------------------------------------------- message.set_date((time_t) email.date.to_unix(), (int) (email.date.get_utc_offset() / TimeSpan.HOUR)); --------------------------------------------------------- If it is changed to: --------------------------------------------------------- message.set_date((time_t) email.date.to_unix(), 0); --------------------------------------------------------- Then everything works. The MIME message is correct, although it sets the date header to the utc-date with zero offset. That is, it is not the current local time plus the offset, but it is still the correct time. Example: Was in my timezone (Sweden): Date: Wed, 09 Apr 2014 08:35:54 +0002 Should have been: Date: Wed, 09 Apr 2014 08:33:54 +0200 With the fix: Date: Wed, 09 Apr 2014 06:33:54 +0000
Good catch. I tracked this down to a problem with the time zone we were handing to GMime for converting the date, so time zone information is preserved. Pushed to master, commit f38c8c
Could you please apply this patch to the 0.6 branch also?
I wasn't planning on generating another dot release for 0.6. Is there a reason in particular you want this patch applied?
(In reply to comment #5) > I wasn't planning on generating another dot release for 0.6. Is there a reason > in particular you want this patch applied? Maybe I should have asked earlier. As this bug is rather annoying and we've got a Fedora bug for it (https://bugzilla.redhat.com/show_bug.cgi?id=1121306), we apply the fix also to the 0.6 packages.
I didn't realize this bug was causing all the problems mentioned in the ticket. Do you need a patch applied to the branch, or do we need to roll another tarball?
I've pushed this commit to the geary-0.6 branch. We're going to roll an 0.6.3 release soon, so this will be in that as well.
Now available in Geary 0.6.3.