Recognizing threads with IMAP.

User Help for Mozilla Thunderbird
MicheleBS
Posts: 86
Joined: May 11th, 2012, 11:14 am

Recognizing threads with IMAP.

Post by MicheleBS »

Dear Forum,

I've just moved from POP3 to IMAP with my e-mail account in Thunderbird, in order to manage my messages and folders also through the smartphone, for quick replies and less important questions, like reading newsletters.

However, I noticed that if I send an e-mail from my webmail, when Thunderbird synchronizes its "Sent" folder with the server one, and so downloads the message I sent through the Internet, it doesn't recognise such a message as a reply, and it doesn't include it in the related thread.

This is a bit annoying: I've been using the "thread" visualisation in Thunderbird with since years: it's comfortable, also to view the single messages as parts of the same conversation.

Generally, I see that with IMAP there's some difficulty for Thunderbird to understand the belonging of the messages to the conversations.

I fear that this depends also on the remote e-mail server. Is there something I could do, mauybe to assign manually a message to a conversation?

Thanks thanks.
alta88
Posts: 1029
Joined: January 28th, 2006, 3:08 pm

Re: Recognizing threads with IMAP.

Post by alta88 »

There isn't a way to do this natively if the message doesn't contain a References or In-Reply-To header to a parent mail (or using a trick like threading by subject). However, the TotalMessage extension implements drag and drop rethreading and I believe HeaderTools lets you edit headers to achieve this.
mgagnonlv
Posts: 848
Joined: February 12th, 2005, 8:33 pm

Re: Recognizing threads with IMAP.

Post by mgagnonlv »

Threads are identified by hidden resources that you see in the source code. Some programs discard that information when you reply to a message. Then Thunderbird cannot do anything afterwards. Likewise, if the webmail program throws all replies in the Sent mail folder, then there is nothing you can do – except manual labour – to keep them in the same folder as the original message.

This is one of the reasons why I rarely reply to messages via webmail or by phone.
Michel Gagnon
Montréal (Québec, Canada)
User avatar
tanstaafl
Moderator
Posts: 49647
Joined: July 30th, 2003, 5:06 pm

Re: Recognizing threads with IMAP.

Post by tanstaafl »

There is a difference between recognizing a message as a reply and as part of a conversation. Usually a reply is part of a conversation, but a separate flag is used to indicate that its a reply. Thunderbird typically uses the References/In-Reply-To headers to determine if a message is part of a conversation. If you reply to a message using webmail that won't set the reply flag for the message in the inbox.msf file and/or update the X-Mozilla-Status header in the mbox file, so when you look at that folder listing in Thunderbird it won't understand that its a reply. But either a References or a In-Reply-To header should still be there for Thunderbird to recognize its part of a conversation .

I'm not aware of any differences between POP and IMAP accounts that would effect recognizing threading. http://kb.mozillazine.org/Stop_threading_by_subject mentions several settings that effect whether Thunderbird recognizes a messages part of a thread. I suggest you use view -> message source or control-U and look at the headers of the message and figure out if the information was available for Thunderbird to recognize it as part of a thread, and was Thunderbird probably configured to do so. It might be as simple as you're configured to rely only upon the subject to recognize threads, and webmail didn't add the Re: prefix.
User avatar
tanstaafl
Moderator
Posts: 49647
Joined: July 30th, 2003, 5:06 pm

Re: Recognizing threads with IMAP.

Post by tanstaafl »

Did your problem go away? I'd be happy to look at a sanitized copy of the headers for a message (where you replaced any email addresses with some generic text) and try to figure out whether it should have been treated as part of a conversation if you used default thread settings. You can use control-U or view -> message source to look at the raw message source.
MicheleBS
Posts: 86
Joined: May 11th, 2012, 11:14 am

Re: Recognizing threads with IMAP.

Post by MicheleBS »

Dear alta88, dear mgagnonlv, dear tanstaafl,

Thank you and thank you again for yor support and suggests.

@tanstaafl: as soon as possible, I will check the aspects tou are mentioning to, and will post here some headers.
MicheleBS
Posts: 86
Joined: May 11th, 2012, 11:14 am

Re: Recognizing threads with IMAP.

Post by MicheleBS »

This is an e-mail I sent to a friend, which would become the beginning of a conversation:

Code: Select all

X-Mozilla-Keys:                                                                                 
To: [Recipient]
From: [Me]
Subject: Un saluto.
Message-ID: <068f57a2-92cb-8cb6-a38a-d120a948c480@bartolettistella.net>
Date: Wed, 9 Nov 2016 10:37:10 +0100
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101
 Thunderbird/45.4.0
MIME-Version: 1.0
Content-Type: multipart/alternative;
 boundary="------------CB285A1E04C292BCE7F7FB1A"

This is a multi-part message in MIME format.
--------------CB285A1E04C292BCE7F7FB1A
Content-Type: text/plain; charset=windows-1252; format=flowed
Content-Transfer-Encoding: 8bit

[Text body]


--------------CB285A1E04C292BCE7F7FB1A
Content-Type: text/html; charset=windows-1252
Content-Transfer-Encoding: 8bit

[HTML Text body]

--------------CB285A1E04C292BCE7F7FB1A--
The first of my friend's replies:

Code: Select all

From - Wed Nov 09 10:51:50 2016
X-Account-Key: account5
X-UIDL: 1478684995.27063.mxavas10.ad.aruba.it,S=7852
X-Mozilla-Status: 0013
X-Mozilla-Status2: 00000000
X-Mozilla-Keys:                                                                                 
Return-Path: [Sender]
Delivered-To: [Recipient]
Received: (qmail 27061 invoked by uid 89); 9 Nov 2016 09:49:55 -0000
Received: by simscan 1.2.0 ppid: 4345, pid: 25758, t: 8.3482s
         scanners: clamav: 0.97-exp/m:53 spam: 3.3.1
X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mxavas10.ad.aruba.it
X-Spam-Level: 
X-Spam-Status: No, score=0.0 required=5.0 tests=FREEMAIL_FROM,HTML_MESSAGE autolearn=disabled version=3.3.1
Received: from unknown (HELO mxcmd06.ad.aruba.it) (62.149.157.40)
  by mxavas10.ad.aruba.it with SMTP; 9 Nov 2016 09:49:47 -0000
Received: from BLU004-OMC2S29.hotmail.com ([65.55.111.104])
	by mxcmd06.ad.aruba.it with bizsmtp
	id 5lpl1u01l2FBfl501lpmct; Wed, 09 Nov 2016 10:49:46 +0100
Received: from EUR02-VE1-obe.outbound.protection.outlook.com ([65.55.111.71]) by BLU004-OMC2S29.hotmail.com 
over TLS secured channel with Microsoft SMTPSVC(7.5.7601.23008);
	 Wed, 9 Nov 2016 01:49:45 -0800
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hotmail.com;
 s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version;
 bh=BTW3zl0szoX0hGtEnf/5xNyarhsLA8DrQYpMQJbmt/Y=;
 b=Kw9Xjwecbkh+ZkXTA1GGbezbZeBuXFgrJhu1D6AZLUvjsTTuVRzEjYdt4lAJj3BJRPayhiJx0J/
CPLLEDjq25zkPLmFbWdlAHvhdTPnPIpaQgVQHCqCfGwHaseTrv8OiLI+agbnyw7xc89Iba/
LV4rW29tT2pXE95cl6div0iUw302/3cNIMUwfOE6VpK14hueyh5rT5e7H1izCQnq1nh
JrkRA6QsRD567VMmmFusy7oOWEOnprJysTB8Cz
+FnOCfCyUKlO4x4BF3en6oeX6SnnwZWNKZhWNTJzd4nrVKChJ946uB/28DV
Ghi9h3q9qEAD7V5Em5OAKdvNzo6ZXLyA==
Received: from VE1EUR02FT055.eop-EUR02.prod.protection.outlook.com
 (10.152.12.53) by VE1EUR02HT118.eop-EUR02.prod.protection.outlook.com
 (10.152.13.78) with Microsoft SMTP Server (version=TLS1_2,
 cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.707.3; Wed, 9 Nov
 2016 09:49:34 +0000
Received: from HE1PR0801MB1899.eurprd08.prod.outlook.com (10.152.12.60) by
 VE1EUR02FT055.mail.protection.outlook.com (10.152.13.34) with Microsoft SMTP
 Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id
 15.1.707.3 via Frontend Transport; Wed, 9 Nov 2016 09:49:34 +0000
Received: from HE1PR0801MB1899.eurprd08.prod.outlook.com ([10.168.94.18]) by
 HE1PR0801MB1899.eurprd08.prod.outlook.com ([10.168.94.18]) with mapi id
 15.01.0693.009; Wed, 9 Nov 2016 09:49:34 +0000
From: [Sender]
To: [Recipient]
Subject: Re: Un saluto.
Thread-Topic: Un saluto.
Thread-Index: AQHSOmzVVDc+UqhNKUmaBe/yPCo7uaDQaDwA
Date: Wed, 9 Nov 2016 09:49:34 +0000
Message-ID: <HE1PR0801MB189943662A10A26207C69BAD83B90@HE1PR0801MB1899.eurprd08.prod.outlook.com>
References: <068f57a2-92cb-8cb6-a38a-d120a948c480@bartolettistella.net>
In-Reply-To: <068f57a2-92cb-8cb6-a38a-d120a948c480@bartolettistella.net>
Accept-Language: it-IT, en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
authentication-results: bartolettistella.net; dkim=none (message not signed)
 header.d=none;bartolettistella.net; dmarc=none action=none
 header.from=hotmail.com;
x-incomingtopheadermarker: OriginalChecksum:;UpperCasedChecksum:;SizeAsReceived:7121;Count:36
x-ms-exchange-messagesentrepresentingtype: 1
x-incomingheadercount: 36
x-eopattributedmessage: 0
x-microsoft-exchange-diagnostics: 1;VE1EUR02HT118;7:AU0HVsFCFUEso
+K8OwY8g5lPntLlUm2q8L6MP79boeUSxS4d6LJNKuUbX8kcsvgxkp
1ZBglSRZN6YKj2gUt5m/llYDHVdluJscpFiffTSZ0VthW8QLuSu0mzIM499ZLKkN04y3hd
+fM+weLrFzP3abdGiYU4EnUqClBe5KU1UnCBB3c/bogruzl5kgkocOWYXKwPX/KxEHqfzpQk
+J2eudBjBasf/9HP8V6xKXApOfLIRH/+sfuhfKcTA27Jtsk492/grNwhp/lFvvQcbpyfaALgPWIe6FAZAVRVEVZfEd6ekawNRlAsntev
XpfVlX0dhSPEiYFSCeQkDN2QUvrMY7a6sGPMqKFN06ZOptwwgLk=
x-forefront-antispam-report: EFV:NLI;SFV:NSPM;SFS:(10019020)(98900003);DIR:OUT;SFP:1102;SCL:1;SRVR:VE1EUR02HT118;H:HE1PR0801MB1899.eurprd08.prod.outlook.com;FPR:
;SPF:None;LANG:it;
x-ms-office365-filtering-correlation-id: 0d72a6da-a634-4129-c979-08d40885b523
x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:(1601124038)(1603103113)(1601125047);SRVR:VE1EUR02HT118;
x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(432015012)(82015046);SRVR:VE1EUR02HT118;
BCL:0;PCL:0;RULEID:;SRVR:VE1EUR02HT118;
x-forefront-prvs: 0121F24F22
spamdiagnosticoutput: 1:99
spamdiagnosticmetadata: NSPM
Content-Type: multipart/alternative;
	boundary="_000_HE1PR0801MB189943662A10A26207C69BAD83B90HE1PR0801MB1899_"
MIME-Version: 1.0
X-OriginatorOrg: hotmail.com
X-MS-Exchange-CrossTenant-originalarrivaltime: 09 Nov 2016 09:49:34.6201
 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Internet
X-MS-Exchange-CrossTenant-id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa
X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1EUR02HT118
Return-Path: [Sender]
X-OriginalArrivalTime: 09 Nov 2016 09:49:45.0067 (UTC) FILETIME=[99F0BBB0:01D23A6E]

--_000_HE1PR0801MB189943662A10A26207C69BAD83B90HE1PR0801MB1899_
Content-Type: text/plain; charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable

[Text body]

--_000_HE1PR0801MB189943662A10A26207C69BAD83B90HE1PR0801MB1899_
Content-Type: text/html; charset="Windows-1252"
Content-ID: <B3030F8E4AD7B34883D35AB767D67DFE@eurprd08.prod.outlook.com>
Content-Transfer-Encoding: quoted-printable

[HTML text body]

--_000_HE1PR0801MB189943662A10A26207C69BAD83B90HE1PR0801MB1899_--
And this is a reply I sent from my Webmail (or maybe I edited in the Webmail, after creating it in Thunderbird):

Code: Select all

Date: Sun, 20 Nov 2016 16:14:54 +0100
Message-Id: <OGY50V$E034115714804F2AFD308C37E82AEE94@bartolettistella.net>
Subject: Re: Un saluto.
MIME-Version: 1.0
X-Sensitivity: 3
Content-Type: multipart/alternative;
	boundary="_=__=_XaM3_.1479654895.2A.14343.42.21802.52.42.007.1864155002"
From: [Sender]
To: [Recipient]
X-XaM3-API-Version: V3(R2)
X-SenderIP: 82.49.208.73


--_=__=_XaM3_.1479654895.2A.14343.42.21802.52.42.007.1864155002
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable


--_=__=_XaM3_.1479654895.2A.14343.42.21802.52.42.007.1864155002
Content-Type: text/html; charset=utf-8
Content-Transfer-Encoding: quoted-printable

[Text body]

--_=__=_XaM3_.1479654895.2A.14343.42.21802.52.42.007.1864155002--
So, the problem of the threading loss appears if I edit through the Webmail also a reply I started writing in Thunderbird.
It seems that whatever the Webmail touches, this goes damaged forever.

What do you suggest me? Is there a way to Re-thread a message manually, as an alternative to TotalMessage? I don't like so much the way it modifies the look of Columns and Headers. Any other extension?

Edited by moderator (tanstaafl) to wrap some lines (mainly DKIM headers which aren't need anyways) to make it fit on the screen.
User avatar
tanstaafl
Moderator
Posts: 49647
Joined: July 30th, 2003, 5:06 pm

Re: Recognizing threads with IMAP.

Post by tanstaafl »

The first reply has both a References: and a In-Reply-To header whose value equals the Message-ID: header of the message you sent. That's exactly what you want. The reply you sent via Webmail doesn't include either of those headers, so I wouldn't expect it to show up as part of the conversation. If it had the same Subject with a Re: prefix and your friends email client was configured to also test the Subject it could work around that. I suspect it wasn't configured to do that since its more error prone, and those two headers have been required by the rfc's for at least 15 years.

You could use the Header Tools Lite add-on to edit the message and copy and paste the References: and In-Reply-To header from the prior message, if you don't like the TotalMessage add-on.

I suggest you see if the problem goes away if you don't use webmail to reply to an existing conversation. It shouldn't cause any problems starting a conversation, because it will add the Message-Id: header needed to uniquely identify the message, that the References: and In-Reply-To header will reference.
MicheleBS
Posts: 86
Joined: May 11th, 2012, 11:14 am

Re: Recognizing threads with IMAP.

Post by MicheleBS »

Thank you tanstaafll.

I began experimenting with Header Tools Lite, trying to understand its operation and the logic under the "Thread view" in Thb. But it's not so clear, to me. In particular, what are the differences between pasting an ID into References or In-Reply-To?

Anyway, more than the "Thread view", I feel really comfortable with the "Conversation view", which is a bit different and more accurate: in a single sight I can browse the entire structure of a verbal crossfire, a "conversation", indeed, with all the messages and replies -both from me to my recipients and from them to me- organized in a multi-tree. And, next to every e-mail, the folder in which it is stored. Really useful.

An example:


I receive a message (1) from a friend, to which I (unluckily) have to reply through the webmail, due to urgency. So, this reply (2) will lose all the references to the original e-mail, and in the so-called Conversation view, Thb will not show me it as a reply. In turn, my friend also replies (3) to my message, and, depending on its client/webmail/server, it will mantain or lose the references to my reply (2) and/or to his first e-mail written to me (1). So, how to re-form the headers, so that I will see all the three e-mails properly related in the "Conversation view", and the two e-mails from him showed into the Inbox folder as belonging to a single Thread, with the (3) as son of the (1)? I don't want the replies from me (2) to be shown in the Inbox folder, but to be kept in the Sent folder. For a global sight, ther's the Conversation window, indeed.

An explanation from you would be very very appreciated, or maybe a simple tutorial/guide on the net. So that I can understand how to behave in general, whenever I want to re-built a Conversation editing the single headers, and correct errors caused by the webmail disturbances.

Thanks.
User avatar
tanstaafl
Moderator
Posts: 49647
Joined: July 30th, 2003, 5:06 pm

Re: Recognizing threads with IMAP.

Post by tanstaafl »

My impression is that either the References: (Thunderbird checks for it first) or In-Reply-To: (checks for it second) header is sufficient, though setting both would be best because the less assumptions you make about how conforming to the rfc's the recipients email client is, the better. If its missing use the header tools lite add-on to edit the message, adding the References: header. Set it equal to the Message-Id of the original message. I'd add it before the Content-Type header. Thunderbird seems to add References: right after the To: and In-Reply-To: right after the MIME-Version: but I've seen those headers in multiple locations.

Think about creating a dedicated folder for each person you regularly correspond with. You'd create a message filter to move any incoming new mail to the corresponding folder for that person. Check "place replies in the folder of the message being replied to" in the accounts "copies & folders" settings. Once you do that, and manually move any existing messages, if you reply to a message in the current folder all of your correspondence with that person should be in "their" folder. Its a bit of work, but seems to be the best way to completely view a conversation. If some of the messages in a conversation are in the inbox and some in the sent folder you're not going to see the whole conversation. However, this scheme is not going to work well if you intermingle replying via Thunderbird and via webmail because webmail won't save replies in the same location. Its a tradeoff.
MicheleBS
Posts: 86
Joined: May 11th, 2012, 11:14 am

Re: Recognizing threads with IMAP.

Post by MicheleBS »

Thank you tanstaafl.

Some days from our last contact, but I wanted to experiment.

***

I'm quite devoted to the Conversation view, because any message I select, both in Inbox and Sent folders, if I press Ctrl+Shift+O I immediately can view in a separate new tab the structure of the e-mail; it's a comfortable and lightweight way, both for me and Thb.

Moreover, I'd prefer not to create single folders for every correspondent/friend, as you suggest, because in fact what I call my "Conversations" are most of all brief correspondences with lots of different and new contacts, more than long conversations with a few friends. And, you're right, with webmail I could encounter further troubles, because it doesn't apply the rule place replies in the folder of the message being replied to. And it's comfortable for me to still mantain Inbox and Sent as separate folders; maybe only a matter of habit, I don't know.

So, I'm trying to understand how to operate on the header of an e-mail to correctly re-assign it to its Conversation, positioning it in the proper point of the structure. But it's not so simple; in particular, I notice that Thunderbird often doesn't have the Message -> Open in Conversation command active, and I really don't know why. In theory, it should be able to open the Conversation tab for every message, also as the unique item of the Conversation (for example, an e-mail received for the first time from a quite new contact). And sometimes this is possible, indeed. But often this is forbidden: the command is disabled, also for messages correctly recognized, in the Thread view, as part of a larger conversation. And there are other e-mails of the same conversation that I can open in a Conversation tab: that way, it happens that also the e-mails woth the command "Conversation" disabled are included in the structure.

Image | Image | Image


It seems that References: and In-Reply-To: are not the only headers to work with. Or not completely that way, at least. For example, I see that References: admits more than one ID, both from the first e-mail ("root e-mail") and the following ones (following replies and others), but I can't understand how to list them: which ID first?.

...

A little boredom. The fact is that, in the end, IMAP is precious and comfortable, for me.
Most of all, I can immediately find all my drafts on the smartphone or wherever, and I can edit them on the go, when I'm around outside. I can eventually decide to send them through Thb, later, not to encounter troubles with the headers, but I can accomplish them, at least.

Any of your suggestions will be really appreciated.
User avatar
tanstaafl
Moderator
Posts: 49647
Joined: July 30th, 2003, 5:06 pm

Re: Recognizing threads with IMAP.

Post by tanstaafl »

Could you post an example of those two headers with multiple IDs (since they shouldn't have a persons full email address in the header)? If there are any other headers that reference those IDs please include them too.
MicheleBS
Posts: 86
Joined: May 11th, 2012, 11:14 am

Re: Recognizing threads with IMAP.

Post by MicheleBS »

Dear tanstaafl, here is a typical "Conversation" with 4 messages, as Thunderbird comfortably recognizes it scanning both in the Inbox and Sent folders. The 4 messages, so, belong to different folders: 2 within Inbox and 2 within Sent.

1- At the beginning I wrote a message to my recipient (Message 1);
2- My recipient replied me (Message 2);
3- I replied to his reply (Message 3);
4. He replied to this last e-mail I sent him (Message 4).

It would be wonderful if you help me to understand what voices in the headers of the messages Thunderbird uses to recognize the Conversation and properly shows it. In that case, I would be able to edit the headers consciously, adding/removing/correcting them and -in the end- rebuilt the conversation itself. With IMAP, indeed, now no Conversation is recognized correctly: in most cases, the e-mails are listed as single Conversations, made each one of only a unique message. But, more frequently, Conversations are not recognized at all, with the "Open Message in Conversation" command disabled (see previous post).

Your attention and support is very precious, for me.

Image

Message 1 Header:

Code: Select all

From - Wed Aug 03 16:22:41 2016
X-Mozilla-Status: 0001
X-Mozilla-Status2: 00800000
X-Mozilla-Keys:                                                                                 
To: info@...
From: Michele Bartoletti Stella <michele@...>
Subject: Confronto: SL88 Studio - Acuna.
Message-ID: <4232a91c-30cc-2c11-4a8f-cb016c5494a8@bartolettistella.net>
Date: Wed, 3 Aug 2016 16:22:40 +0200
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101
 Thunderbird/45.2.0
MIME-Version: 1.0
Content-Type: multipart/alternative;
 boundary="------------636B3567D0625EF8E01F25D0"

This is a multi-part message in MIME format.
--------------636B3567D0625EF8E01F25D0
Content-Type: text/plain; charset=windows-1252; format=flowed
Content-Transfer-Encoding: 8bit

Gentile Studiologic,

...

--------------636B3567D0625EF8E01F25D0--

Message 2 Header:

Code: Select all

From - Wed Aug 03 22:02:06 2016
X-Account-Key: account5
X-UIDL: 1470244071.30731.mxavas13.ad.aruba.it,S=4701
X-Mozilla-Status: 0013
X-Mozilla-Status2: 00000000
X-Mozilla-Keys:                                                                                 
Return-Path: <info@...
Delivered-To: michele@...
Received: (qmail 31622 invoked by uid 89); 3 Aug 2016 17:05:31 -0000
Received: from unknown (HELO mxcmd08.ad.aruba.it) (10.10.10.80)
  by mxavas13.ad.aruba.it with SMTP; 3 Aug 2016 17:05:31 -0000
Received: from dd31412.kasserver.com ([85.13.149.73])
	by mxcmd08.ad.aruba.it with bizsmtp
	id Sh5W1t00r1bFJ4501h5Wxt; Wed, 03 Aug 2016 19:05:31 +0200
Received: from dd31412.kasserver.com (dd0803.kasserver.com [85.13.146.34])
	by dd31412.kasserver.com (Postfix) with ESMTPSA id 2A22E100849
	for <michele@...; Wed,  3 Aug 2016 19:05:30 +0200 (CEST)
MIME-Version: 1.0
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
X-SenderIP: 79.46.66.158
User-Agent: ALL-INKL Webmail 2.11
In-Reply-To: <4232a91c-30cc-2c11-4a8f-cb016c5494a8@bartolettistella.net>
References: <4232a91c-30cc-2c11-4a8f-cb016c5494a8@bartolettistella.net>
Subject: Re: Confronto: SL88 Studio - Acuna.
From: "GG" <info@...
To: michele@...
Message-Id: <20160803170530.2A22E100849@dd31412.kasserver.com>
Date: Wed,  3 Aug 2016 19:05:30 +0200 (CEST)
X-Spam-Rating: mxavas13.ad.aruba.it 1.6.2 0/1000/N
X-Antivirus: avast! (VPS 160803-1, 03/08/2016), Inbound message
X-Antivirus-Status: Clean

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www=
=2Ew3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html lang=3D"de" xml:lang=
=3D"en" xmlns=3D"http://www.w3.org/1999/xhtml"><head><meta http-equiv=3D"Co=
ntent-Type" content=3D"text/html charset=3DISO-8859-1" /><title></title><st=
yle type=3D"text/css">html,body{font-size:12px;background-color:#fff;color:=
#333;font-family:sans-serif,Arial,Verdana,Trebuchet MS;line-height:1.4;}</s=
tyle></head><body><p>Salve Michele,</p>

...

Message 3 Header:

Code: Select all

From - Fri Aug 05 00:57:25 2016
X-Mozilla-Status: 0001
X-Mozilla-Status2: 00800000
X-Mozilla-Keys:                                                                                 
Subject: Re: Confronto: SL88 Studio - Acuna.
To: GG <info@...
References: <4232a91c-30cc-2c11-4a8f-cb016c5494a8@bartolettistella.net>
 <20160803170530.2A22E100849@dd31412.kasserver.com>
From: Michele Bartoletti Stella <michele@...>
Message-ID: <70d2882a-4533-ff07-9250-69cef8545c16@bartolettistella.net>
Date: Fri, 5 Aug 2016 00:57:23 +0200
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101
 Thunderbird/45.2.0
MIME-Version: 1.0
In-Reply-To: <20160803170530.2A22E100849@dd31412.kasserver.com>
Content-Type: multipart/alternative;
 boundary="------------AE72830FC2F41AF9098428C4"

This is a multi-part message in MIME format.
--------------AE72830FC2F41AF9098428C4
Content-Type: text/plain; charset=windows-1252; format=flowed
Content-Transfer-Encoding: 8bit

Grazie mille ...

--------------AE72830FC2F41AF9098428C4--

Message 4 Header:

Code: Select all

From - Mon Aug 08 23:55:41 2016
X-Account-Key: account5
X-UIDL: 1470469265.20931.mxavas3.ad.aruba.it,S=6298
X-Mozilla-Status: 0011
X-Mozilla-Status2: 00000000
X-Mozilla-Keys:                                                                                 
Return-Path: <info@...
Delivered-To: michele@...
Received: (qmail 20929 invoked by uid 89); 6 Aug 2016 07:41:05 -0000
Received: from unknown (HELO mxcmd10.ad.aruba.it) (10.10.10.82)
  by mxavas3.ad.aruba.it with SMTP; 6 Aug 2016 07:41:05 -0000
Received: from dd31412.kasserver.com ([85.13.149.73])
	by mxcmd10.ad.aruba.it with bizsmtp
	id Tjh41t01t1bFJ4501jh54u; Sat, 06 Aug 2016 09:41:05 +0200
Received: from dd31412.kasserver.com (dd0802.kasserver.com [85.13.143.1])
	by dd31412.kasserver.com (Postfix) with ESMTPSA id 8FA9010028D
	for <michele@...; Sat,  6 Aug 2016 09:41:04 +0200 (CEST)
MIME-Version: 1.0
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
X-SenderIP: 79.35.4.94
User-Agent: ALL-INKL Webmail 2.11
In-Reply-To: <70d2882a-4533-ff07-9250-69cef8545c16@bartolettistella.net>
References: <4232a91c-30cc-2c11-4a8f-cb016c5494a8@bartolettistella.net>
 <20160803170530.2A22E100849@dd31412.kasserver.com><70d2882a-4533-ff07-9250-69cef8545c16@bartolettistella.net>
Subject: Re: Confronto: SL88 Studio - Acuna.
From: "GG" <info@...
To: michele@...
Message-Id: <20160806074104.8FA9010028D@dd31412.kasserver.com>
Date: Sat,  6 Aug 2016 09:41:04 +0200 (CEST)
X-Spam-Rating: mxavas3.ad.aruba.it 1.6.2 0/1000/N
X-Antivirus: avast! (VPS 160808-6, 08/08/2016), Inbound message
X-Antivirus-Status: Clean

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www=
=2Ew3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html lang=3D"de" xml:lang=
=3D"en" xmlns=3D"http://www.w3.org/1999/xhtml"><head><meta http-equiv=3D"Co=
ntent-Type" content=3D"text/html charset=3DISO-8859-1" /><title></title><st=
yle type=3D"text/css">html,body{font-size:12px;background-color:#fff;color:=
#333;font-family:sans-serif,Arial,Verdana,Trebuchet MS;line-height:1.4;}</s=
tyle></head><body><p>Salve Michele,</p>
MicheleBS
Posts: 86
Joined: May 11th, 2012, 11:14 am

Re: Recognizing threads with IMAP.

Post by MicheleBS »

tanstaafl wrote:Could you post an example of those two headers with multiple IDs (since they shouldn't have a persons full email address in the header)? If there are any other headers that reference those IDs please include them too.
Dear tanstaafl, could you examine the headers I posted?
Any help from you in understanding this logic will be appreciated!

;-)
User avatar
tanstaafl
Moderator
Posts: 49647
Joined: July 30th, 2003, 5:06 pm

Re: Recognizing threads with IMAP.

Post by tanstaafl »

Sorry about the delay, I lost track of this thread. rfc2822 at http://www.faqs.org/rfcs/rfc2822.html is the standard I looked at.

message1 has Message-ID: header <4232a91c-30cc-2c11-4a8f-cb016c5494a8@bartolettistella.net>
A Message-Id header is a way to uniquely identify a message. In-Reply-To and References headers identify what messages are in a conversation by mentioning their Message-Ids. They don't have to mention every message, just the parent messages. What can get confusing is when a conversation starts to get multiple parents.

message2 has Message-ID: <HE1PR0801MB189943662A10A26207C69BAD83B90@HE1PR0801MB1899.eurprd08.prod.outlook.com>
has In-Reply-To: <4232a91c-30cc-2c11-4a8f-cb016c5494a8@bartolettistella.net>
and References: <4232a91c-30cc-2c11-4a8f-cb016c5494a8@bartolettistella.net>
thats fine, its saying its in a conversation that includes message 1.

message3 has Message-ID: <70d2882a-4533-ff07-9250-69cef8545c16@bartolettistella.net>
has References: <4232a91c-30cc-2c11-4a8f-cb016c5494a8@bartolettistella.net>
<20160803170530.2A22E100849@dd31412.kasserver.com>
has In-Reply-To: <20160803170530.2A22E100849@dd31412.kasserver.com>

The References: header seems to be saying its in a conversation with message 1 and some unknown message. I don't understand why In-Reply-To only mentions the unknown message. If message3 doesn't get listed as part of the conversation with message1 and message2 perhaps its because Thunderbird is using In-Reply-To instead of References:.

message4 has In-Reply-To: <70d2882a-4533-ff07-9250-69cef8545c16@bartolettistella.net>
References: <4232a91c-30cc-2c11-4a8f-cb016c5494a8@bartolettistella.net> thats message1
<20160803170530.2A22E100849@dd31412.kasserver.com> thats the unknown message again
<70d2882a-4533-ff07-9250-69cef8545c16@bartolettistella.net> thats message 3
In-Reply-To: <70d2882a-4533-ff07-9250-69cef8545c16@bartolettistella.net>

The References header seems fine. It mentions your parent message, the unknown message which is probably another parent, and then your message 3 (which I think is optional). If its displayed as part of a 2 message (not 4 message) conversation it might because In-Reply-To only mentions message 3's Message-Id.

I don't know of a setting to tell it to use just the References: header. I suspect the code assumes that if both a References and a In-Reply-To header exist that they may have different values, but should list the same parent messages. In your case, they don't. I suggest you experiment by adding the missing Message-Ids to the In-Reply-To header and see what effect that has.
Post Reply