Bug 260761 - akonadi fails to parse date on some rfc822 messages
Summary: akonadi fails to parse date on some rfc822 messages
Status: RESOLVED UNMAINTAINED
Alias: None
Product: kdepimlibs
Classification: Applications
Component: kmime (show other bugs)
Version: unspecified
Platform: Gentoo Packages Linux
: NOR normal
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-12-20 03:25 UTC by Marc Schiffbauer
Modified: 2017-01-07 22:02 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
testmail with specific date header (499 bytes, application/mbox)
2010-12-20 03:25 UTC, Marc Schiffbauer
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Marc Schiffbauer 2010-12-20 03:25:17 UTC
Created attachment 55092 [details]
testmail with specific date header

Version:           unspecified (using Devel) 
OS:                Linux

I noticed, that some mails are shown with a date "Unknown" in kmail2.

Looking deeper with akonadiconsole akonadi has no date in the Browser for such messages too.

Affected are at least all mails with the following "Date:" header format:

Date: Sat, 18 Dec 2010 14:01:21 "GMT"

Maybe the problem is the "GMT" or the quotes around it.
(X-mailer: AspMail 3.02 (QSMTEF5782))

mutt can handle that mail without any problems (as well as the webmail that I am using)



Reproducible: Always

Steps to Reproduce:
* Put a Mail with a Date: header like this into your mailbox:
  Date: Sat, 18 Dec 2010 14:01:21 "GMT"


Actual Results:  
* Read that mail kmail2 or akonadiconsole it will show "Unknown" in kmails message list and "Date:	Sun Feb  7 07:28:15 2106" in the mailview.


Expected Results:  
Date should be read correctly and displayed according to the local timezone
Comment 1 Volker Krause 2010-12-30 14:21:47 UTC

*** This bug has been marked as a duplicate of bug 258069 ***
Comment 2 Volker Krause 2010-12-30 14:22:48 UTC
Sorry, mixed up bug numbers here.
Comment 3 Marc Schiffbauer 2012-03-19 21:15:08 UTC
This Bug is still present (akonadi 1.7.1 / KDE 4.8.1)
Comment 4 Marc Schiffbauer 2012-05-20 10:42:34 UTC
This bug is still present (4.8.3+ (current 4.8 git branch, akonadi 1.7.2)
Comment 5 Marc Schiffbauer 2012-05-20 10:48:42 UTC
Additional note: when kmail is configured to jump to the newest message when selecting a folder it will fail on folders which contain messages with dates that akonadi cannot handle properly and jump to some of those messages with an "Unknown" date instead (which are listed at the very end of the list).
Comment 6 Marc Schiffbauer 2012-05-24 09:07:19 UTC
Hi Volker,

I just had a look at RFC 5322. Having "GMT" as Timezone in the Date Header is supported but deprecated. However, those mails I am having Problems with seem to be created by some mail software where they misunderstood the RFC a little bit. ( http://tools.ietf.org/html/rfc5322#page-33 )

The RFC talks about "GMT" but the double uotes are not part of the real String that can be used. E.g. it should be written as GMT and not "GMT". So the example mail is indeed not 100% RFC compatible.

However: I really think this kind of header should nevertheless be parsed as expected because real world shows that there *are* mails like this in the peoples mailboxes. 

So please accept "<some RFC 5322 obs-zone>" (with double quotes) as well as without (which should already be the case) 

*And* mutt for example does not have a problem with those mails...

-Marc
Comment 7 Martin Koller 2012-07-14 09:12:36 UTC
Git commit d1786732b10d1df4e73fe3aac034d4db6d05447b by Martin Koller.
Committed on 14/07/2012 at 11:11.
Pushed by mkoller into branch 'KDE/4.9'.

enhance date-time parser to allow formats which were possible in KDE3
Related: bug 54098

M  +65   -17   kmime/kmime_header_parsing.cpp
M  +39   -0    kmime/tests/auto/headertest.cpp

http://commits.kde.org/kdepimlibs/d1786732b10d1df4e73fe3aac034d4db6d05447b
Comment 8 Martin Koller 2012-07-14 09:15:40 UTC
Git commit 7d8bbdfb09965fc0a2ec1bfdf1bb290497fa5464 by Martin Koller.
Committed on 14/07/2012 at 11:11.
Pushed by mkoller into branch 'master'.

enhance date-time parser to allow formats which were possible in KDE3
Related: bug 54098

M  +65   -17   kmime/kmime_header_parsing.cpp
M  +39   -0    kmime/tests/auto/headertest.cpp

http://commits.kde.org/kdepimlibs/7d8bbdfb09965fc0a2ec1bfdf1bb290497fa5464
Comment 9 Martin Koller 2012-07-14 09:17:36 UTC
Git commit 72d7e6063c2cf275ad9a09669357b8c7bcfc2d69 by Martin Koller.
Committed on 14/07/2012 at 11:11.
Pushed by mkoller into branch 'KDE/4.8'.

enhance date-time parser to allow formats which were possible in KDE3
Related: bug 54098

M  +65   -17   kmime/kmime_header_parsing.cpp
M  +39   -0    kmime/tests/auto/headertest.cpp

http://commits.kde.org/kdepimlibs/72d7e6063c2cf275ad9a09669357b8c7bcfc2d69
Comment 10 Marc Schiffbauer 2012-07-15 00:57:20 UTC
Thanks for your patch, but this bug is not fixed by that
Comment 11 Denis Kurz 2016-09-24 20:56:20 UTC
This bug has only been reported for versions before 4.14, which have been unsupported for at least two years now. Can anyone tell if this bug still present?

If noone confirms this bug for a Framework-based version of kdepim (version 5.0 or later, as part of KDE Applications 15.08 or later), it gets closed in about three months.
Comment 12 Denis Kurz 2017-01-07 22:02:27 UTC
Just as announced in my last comment, I close this bug. If you encounter it again in a recent version (at least 5.0 aka 15.08), please open a new one unless it already exists. Thank you for all your input.