From: Mark Walters Date: Mon, 21 Apr 2014 07:20:13 +0000 (+0100) Subject: Re: [RFC PATCH] Re: excessive thread fusing X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=83e203dfa4214d8f920a5d020e279e1b58f3e6e2;p=notmuch-archives.git Re: [RFC PATCH] Re: excessive thread fusing --- diff --git a/d2/0d982a986fd24aa681957699d55516e08d7d8c b/d2/0d982a986fd24aa681957699d55516e08d7d8c new file mode 100644 index 000000000..71443547e --- /dev/null +++ b/d2/0d982a986fd24aa681957699d55516e08d7d8c @@ -0,0 +1,122 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by olra.theworths.org (Postfix) with ESMTP id D4B69431FBD + for ; Mon, 21 Apr 2014 00:20:38 -0700 (PDT) +X-Virus-Scanned: Debian amavisd-new at olra.theworths.org +X-Spam-Flag: NO +X-Spam-Score: 1.748 +X-Spam-Level: * +X-Spam-Status: No, score=1.748 tagged_above=-999 required=5 + tests=[DKIM_ADSP_CUSTOM_MED=0.001, FREEMAIL_FROM=0.001, + NML_ADSP_CUSTOM_MED=1.2, RCVD_IN_BL_SPAMCOP_NET=1.246, + RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled +Received: from olra.theworths.org ([127.0.0.1]) + by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) + with ESMTP id kBSCB2RdeJsn for ; + Mon, 21 Apr 2014 00:20:33 -0700 (PDT) +Received: from mail1.qmul.ac.uk (mail1.qmul.ac.uk [138.37.6.7]) + (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) + (No client certificate requested) + by olra.theworths.org (Postfix) with ESMTPS id D60BB431FBC + for ; Mon, 21 Apr 2014 00:20:32 -0700 (PDT) +Received: from smtp.qmul.ac.uk ([138.37.6.40]) + by mail1.qmul.ac.uk with esmtp (Exim 4.71) + (envelope-from ) + id 1Wc8We-0002vD-Ik; Mon, 21 Apr 2014 08:20:24 +0100 +Received: from 92.41.113.2.threembb.co.uk ([92.41.113.2] helo=localhost) + by smtp.qmul.ac.uk with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.71) + (envelope-from ) + id 1Wc8Wc-00084t-Rc; Mon, 21 Apr 2014 08:20:24 +0100 +From: Mark Walters +To: Carl Worth , David Bremner , + notmuch +Subject: Re: [RFC PATCH] Re: excessive thread fusing +In-Reply-To: <877g6kmcmh.fsf@qmul.ac.uk> +References: <87ioq5mrbz.fsf@maritornes.cs.unb.ca> <87fvl8mpzj.fsf@qmul.ac.uk> + <87oazwjq1e.fsf@yoom.home.cworth.org> <877g6kmcmh.fsf@qmul.ac.uk> +User-Agent: Notmuch/0.15.2+615~g78e3a93 (http://notmuchmail.org) Emacs/23.4.1 + (x86_64-pc-linux-gnu) +Date: Mon, 21 Apr 2014 08:20:13 +0100 +Message-ID: <8738h7kv2q.fsf@qmul.ac.uk> +MIME-Version: 1.0 +Content-Type: text/plain; charset=us-ascii +X-Sender-Host-Address: 92.41.113.2 +X-QM-Geographic: According to ripencc, + this message was delivered by a machine in Britain (UK) (GB). +X-QM-SPAM-Info: Sender has good ham record. :) +X-QM-Body-MD5: 8a16c4ce3446ced77f5af078ac173251 (of first 20000 bytes) +X-SpamAssassin-Score: 0.0 +X-SpamAssassin-SpamBar: / +X-SpamAssassin-Report: The QM spam filters have analysed this message to + determine if it is + spam. We require at least 5.0 points to mark a message as spam. + This message scored 0.0 points. Summary of the scoring: + * 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail + provider * (markwalters1009[at]gmail.com) +X-QM-Scan-Virus: ClamAV says the message is clean +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.13 +Precedence: list +List-Id: "Use and development of the notmuch mail system." + +List-Unsubscribe: , + +List-Archive: +List-Post: +List-Help: +List-Subscribe: , + +X-List-Received-Date: Mon, 21 Apr 2014 07:20:39 -0000 + + +>> I haven't tracked through all the logic of the existing algorithm for +>> this case. But I don't like hearing that notmuch constructs different +>> threads for the same messages presented in different orders. This sounds +>> like a bug separate from what we've discussed above. + +I think I have now found this bug and it is separate from the malformed +In-Reply-To problems. + +The problem is that when we merge threads we update all the thread-ids +of documents in the loser thread. But we don't (if I understand the code +correctly) update dangling "metadata" references to threads which don't +(yet) have any documents. + +To make this explicit consider the 2 messages 17,18 in the set. + +Message 17 has id <87wrkidfrh.fsf@pinto.chemeng.ucl.ac.uk> and has no +references/in-reply-to so has no parents. + +Message 18 has a reference to <87wrkidfrh.fsf@pinto.chemeng.ucl.ac.uk> +and an in-reply-to to and +<87wrkidfrh.fsf@pinto.chemeng.ucl.ac.uk> + +If you add 17 first then it gets thread-id 1 and then when you add 18 message 18 gets +thread-id 2 as does the dangling link to the "unseen" message +e.fraga@ucl.ac.uk, and then message 17 is moved to thread-id 2. + +However, if you add 18 first then it gets thread-id 1 and the dangling +link gets id 1. When 17 is added it gets thread-id 2, message 18 gets +thread-id updated to 2 *but* the dangling link to e.fraga@ucl.ac.uk does +not get updated so stays thread-id 1. + +In particular when 52 comes along with its link to e.fraga@ucl.ac.uk +then: + + In the first case it gets put in thread-id 3 and the other two + messages get moved into thread 3. + + In the second case, message 52 gets put in thread 3 and thread 1 + (the dangling link) gets moved into thread 3 leaving thread 2 + (containing messages 17 and 18) untouched. + +Best wishes + +Mark + + + + +