[PATCH v2 00/14] reply refactor, fixes
[notmuch-archives.git] / ff / 0ac4883357d50726ae451e107d18ec8259972f
1 Return-Path: <m.walters@qmul.ac.uk>\r
2 X-Original-To: notmuch@notmuchmail.org\r
3 Delivered-To: notmuch@notmuchmail.org\r
4 Received: from localhost (localhost [127.0.0.1])\r
5         by olra.theworths.org (Postfix) with ESMTP id 30B42431FAF\r
6         for <notmuch@notmuchmail.org>; Thu,  2 Aug 2012 00:19:45 -0700 (PDT)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: -1.098\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-1.098 tagged_above=-999 required=5\r
12         tests=[DKIM_ADSP_CUSTOM_MED=0.001, FREEMAIL_FROM=0.001,\r
13         NML_ADSP_CUSTOM_MED=1.2, RCVD_IN_DNSWL_MED=-2.3] autolearn=disabled\r
14 Received: from olra.theworths.org ([127.0.0.1])\r
15         by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
16         with ESMTP id sQcFunOa+TPZ for <notmuch@notmuchmail.org>;\r
17         Thu,  2 Aug 2012 00:19:44 -0700 (PDT)\r
18 Received: from mail2.qmul.ac.uk (mail2.qmul.ac.uk [138.37.6.6])\r
19         (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))\r
20         (No client certificate requested)\r
21         by olra.theworths.org (Postfix) with ESMTPS id 881F7431FAE\r
22         for <notmuch@notmuchmail.org>; Thu,  2 Aug 2012 00:19:44 -0700 (PDT)\r
23 Received: from smtp.qmul.ac.uk ([138.37.6.40])\r
24         by mail2.qmul.ac.uk with esmtp (Exim 4.71)\r
25         (envelope-from <m.walters@qmul.ac.uk>)\r
26         id 1Swph4-0004Fs-Da; Thu, 02 Aug 2012 08:19:38 +0100\r
27 Received: from 94-192-233-223.zone6.bethere.co.uk ([94.192.233.223]\r
28         helo=localhost)\r
29         by smtp.qmul.ac.uk with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.69)\r
30         (envelope-from <m.walters@qmul.ac.uk>)\r
31         id 1Swph4-0001co-3t; Thu, 02 Aug 2012 08:19:38 +0100\r
32 From: Mark Walters <markwalters1009@gmail.com>\r
33 To: Jani Nikula <jani@nikula.org>, Austin Clements <amdragon@MIT.EDU>,\r
34         notmuch@notmuchmail.org\r
35 Subject: [PATCH] emacs: fix a bug introduced by the recent search cleanups.\r
36 In-Reply-To: <87mx2dais8.fsf@nikula.org>\r
37 References: <1341354059-29396-1-git-send-email-amdragon@mit.edu>\r
38         <1342892232-5659-1-git-send-email-amdragon@mit.edu>\r
39         <1342892232-5659-8-git-send-email-amdragon@mit.edu>\r
40         <87mx2dais8.fsf@nikula.org>\r
41 User-Agent: Notmuch/0.13.2+96~g634443c (http://notmuchmail.org) Emacs/23.4.1\r
42         (x86_64-pc-linux-gnu)\r
43 Date: Thu, 02 Aug 2012 08:19:37 +0100\r
44 Message-ID: <87r4rpsquu.fsf@qmul.ac.uk>\r
45 MIME-Version: 1.0\r
46 Content-Type: text/plain; charset=us-ascii\r
47 X-Sender-Host-Address: 94.192.233.223\r
48 X-QM-SPAM-Info: Sender has good ham record.  :)\r
49 X-QM-Body-MD5: be0b14068fdfc05b5b6d6afd87513faf (of first 20000 bytes)\r
50 X-SpamAssassin-Score: -1.8\r
51 X-SpamAssassin-SpamBar: -\r
52 X-SpamAssassin-Report: The QM spam filters have analysed this message to\r
53         determine if it is\r
54         spam. We require at least 5.0 points to mark a message as spam.\r
55         This message scored -1.8 points.\r
56         Summary of the scoring: \r
57         * -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/,\r
58         *      medium trust\r
59         *      [138.37.6.40 listed in list.dnswl.org]\r
60         * 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail\r
61         provider *      (markwalters1009[at]gmail.com)\r
62         * -0.0 T_RP_MATCHES_RCVD Envelope sender domain matches handover relay\r
63         *      domain\r
64         *  0.5 AWL AWL: From: address is in the auto white-list\r
65 X-QM-Scan-Virus: ClamAV says the message is clean\r
66 X-BeenThere: notmuch@notmuchmail.org\r
67 X-Mailman-Version: 2.1.13\r
68 Precedence: list\r
69 List-Id: "Use and development of the notmuch mail system."\r
70         <notmuch.notmuchmail.org>\r
71 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
72         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
73 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
74 List-Post: <mailto:notmuch@notmuchmail.org>\r
75 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
76 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
77         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
78 X-List-Received-Date: Thu, 02 Aug 2012 07:19:45 -0000\r
79 \r
80 \r
81 In commit 5d0883e the function notmuch-search-next-thread was changed.\r
82 In particular it only goes to the next message if there is a next\r
83 message. This breaks notmuch-show-archive-thread-then-next. Fix this\r
84 by going to the "next" message whenever we are on a current message.\r
85 ---\r
86 \r
87 > On Sat, 21 Jul 2012, Austin Clements <amdragon@MIT.EDU> wrote:\r
88 >> At this point, the only remaining functions that don't support\r
89 >> multi-line search result formats are the thread navigation functions.\r
90 >> This patch fixes that by rewriting them in terms of\r
91 >> notmuch-search-result-{beginning,end}.\r
92 >>\r
93 >> This changes the behavior of notmuch-search-previous-thread slightly\r
94 >> so that if point isn't at the beginning of a result, it first moves\r
95 >> point to the beginning of the result.\r
96 >\r
97 > Hi Austin, bisecting suggests this patch (committed as 5d0883e) breaks\r
98 > notmuch-show-archive-thread-then-next and subsequently\r
99 > notmuch-show-advance-and-archive for me. When showing the last thread in\r
100 > the search results, notmuch-show-archive-thread-then-next used to exit\r
101 > to the end of the search buffer. Now it redisplays the current\r
102 > thread. When I hit SPC to cruise through mails, there's no indication\r
103 > that I've reached the end of search results, other than the same thread\r
104 > being displayed over and over.\r
105 \r
106 This might be the correct fix but I am not certain. It doesn't instantly\r
107 break for me! (It looks more similar to what happened before the parent\r
108 patch.)\r
109 \r
110 Best wishes\r
111 \r
112 Mark\r
113 \r
114 \r
115  emacs/notmuch.el |    2 +-\r
116  1 files changed, 1 insertions(+), 1 deletions(-)\r
117 \r
118 diff --git a/emacs/notmuch.el b/emacs/notmuch.el\r
119 index fd1836f..d2d82a9 100644\r
120 --- a/emacs/notmuch.el\r
121 +++ b/emacs/notmuch.el\r
122 @@ -293,7 +293,7 @@ For a mouse binding, return nil."\r
123  (defun notmuch-search-next-thread ()\r
124    "Select the next thread in the search results."\r
125    (interactive)\r
126 -  (when (notmuch-search-get-result (notmuch-search-result-end))\r
127 +  (when (notmuch-search-get-result)\r
128      (goto-char (notmuch-search-result-end))))\r
129  \r
130  (defun notmuch-search-previous-thread ()\r
131 -- \r
132 1.7.9.1\r
133 \r
134 \r
135 \r