Bug 276105 - Subject with non-ascii letters and without encoding displayed as "???"
Summary: Subject with non-ascii letters and without encoding displayed as "???"
Status: RESOLVED UNMAINTAINED
Alias: None
Product: kmail2
Classification: Applications
Component: message list (show other bugs)
Version: Git (master)
Platform: Unlisted Binaries Linux
: NOR normal
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
: 259051 (view as bug list)
Depends on:
Blocks:
 
Reported: 2011-06-20 07:35 UTC by Murz
Modified: 2017-01-07 22:05 UTC (History)
5 users (show)

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


Attachments
test message (1.62 KB, application/mbox)
2011-11-18 14:00 UTC, Sergei Ivanov
Details
msg1.mbox (2.81 KB, application/octet-stream)
2011-11-21 05:27 UTC, Murz
Details
msg2.mbox (1.36 KB, application/octet-stream)
2011-11-21 05:27 UTC, Murz
Details
msg3.mbox (5.43 KB, application/octet-stream)
2011-11-21 05:27 UTC, Murz
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Murz 2011-06-20 07:35:59 UTC
Version:           Git (master)
OS:                Linux

Very often I receive mail from some services that don't contain encoding description in subject. And non-ascii symbols are displayed like "???" in message list.
Here is example: http://wstaw.org/m/2011/06/20/plasma-desktopcH2810.jpg

The Subject field in mail headers looks like this:
Subject: Âàø ñàéò íå ãîòîâ / Your site is under construction

In kmail 1.x I was successfully see those subjects when set fallback encoding to cp1251, but in kmail 2.1 this option don't change the headers, but acts normally on message body.

So in kmail 1.x I see this subject normally:
Ваш сайт не готов / Your site is under construction

But in kmail 2.x - like this:
��� ���� �� ����� / Your site is under construction

So, this is regression with decode mail headers from kmail 1.x to 2.x.

I can give you some more examples if you needs it and can test this bug in git versions.

Maybe message subject decoding process in 2.x don't look to fallback encoding and always use UTF-8 or Latin-1. Can you tell me some way how to fix this problem?

Reproducible: Always
Comment 1 Murz 2011-06-20 07:37:20 UTC
When subject contains encoding, it displayed normally:

Subject: =?windows-1251?B?ze7i7vHy6CDx4Ony4CBDYXRhbG94eS5ydQ==?=

in kmail 1:
Новости сайта Cataloxy.ru

in kmail 2:
Новости сайта Cataloxy.ru
Comment 2 Sergei Ivanov 2011-11-16 23:05:34 UTC
I confirm this problem with Kmail 4.7.2 on Kubuntu 11.10.

I think Kmail should assume the encoding from "Content-Type:" in the case when
"Subject:" of "From:" is a raw 8-bit text without encoding information.
Comment 3 Murz 2011-11-17 03:38:32 UTC
Outlook, Windows Live, Thunderbird, TheBat and many other mail clients displays headers like described normally (they gets encoding from Content-Type if in Subject it isn't described. 
So the problem is only in KMail2.
Comment 4 Andrey Brizhinev 2011-11-17 06:12:04 UTC
Confirm this issue. KDE 4.7.2, Ubuntu 11.10. Problem only with "Subject", everything else detect encoding right.
Comment 5 Christophe Marin 2011-11-18 12:55:55 UTC
can one of you save one of these wrongly displayed mail in mbox format and attach it to this  report please
Comment 6 Sergei Ivanov 2011-11-18 14:00:06 UTC
Created attachment 65815 [details]
test message

An old message that demonstrates the wrong behavior of Kmail2.
Comment 7 Murz 2011-11-21 05:24:23 UTC
*** Bug 259051 has been marked as a duplicate of this bug. ***
Comment 8 Murz 2011-11-21 05:27:06 UTC
Created attachment 65885 [details]
msg1.mbox
Comment 9 Murz 2011-11-21 05:27:33 UTC
Created attachment 65886 [details]
msg2.mbox
Comment 10 Murz 2011-11-21 05:27:49 UTC
Created attachment 65887 [details]
msg3.mbox
Comment 11 Murz 2011-11-21 05:28:12 UTC
I have attached 3 more examples.
Comment 12 Laurent Montel 2012-01-24 15:27:19 UTC
Question:
I see two different string in messagelist and subject in viewer. Ok it's not good. But for you subject in viewer is correct ?
I tested msg3.mbox.

Could you add screenshot please ? (for msg3)

Thanks.
Comment 13 Murz 2012-01-26 06:54:37 UTC
For msg3 correct subject must be:
Resume-Bank.Ru: Баланс Вашего лицевого счета

I use KDE 4.8 Release, it looks for me like this:
http://wstaw.org/m/2012/01/26/plasma-desktoprD2300.png
Comment 14 Laurent Montel 2012-01-26 09:00:02 UTC
What is your default encoding ?
for me it's not "?" but other letters. But it's right it's not good because in message list and subject it's not the same
Comment 15 Murz 2012-01-26 09:07:11 UTC
I have use English interface with Russian locale.

Here is screenshots of my settings:
http://wstaw.org/m/2012/01/26/plasma-desktopYv2300.png
http://wstaw.org/m/2012/01/26/plasma-desktopla2300.png
http://wstaw.org/m/2012/01/26/plasma-desktopPu2300.png
http://wstaw.org/m/2012/01/26/plasma-desktoplq2300.png
http://wstaw.org/m/2012/01/26/plasma-desktoplq2300.png

I can try to change some settings for checking, tell me what to try.

But, I think, better is to use encoding for mail subject as used for message body (if in subject encoding is miss), instead of try to autodetecting it.
Comment 16 Andrey Brizhinev 2012-12-12 09:09:26 UTC
KDE 4.9.3, Ubuntu 12.10 - problem still exists.
For example: http://i7.minus.com/iViCWcY2gSyVI.png
Subject and body have similar text, but subject is garbled.
There is correct encoding in the headers.
Comment 17 Murz 2013-02-07 06:06:56 UTC
I have tested it in KDE 4.10 RC3 and this but is still here. Can I help or provide more info for testing and resolving this bug?
Comment 18 Murz 2014-03-12 13:59:53 UTC
On KDE 4.12 this bug is still active and annoying: http://wstaw.org/m/2014/03/12/plasma-desktopdk2247.png
Please create some workaround for setup custom encoding for mail headers!
Comment 19 oleg 2014-04-30 21:56:14 UTC
Kde 4.13 bug still present and very annoying
Comment 20 Andrey Brizhinev 2015-03-31 14:14:26 UTC
KDE 4.13.3 - problem still exists!
Comment 21 Denis Kurz 2016-09-24 18:21:52 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 kmail2 (version 5.0 or later, as part of KDE Applications 15.12 or later), it gets closed in about three months.
Comment 22 Denis Kurz 2017-01-07 22:05:48 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.