Re: [PATCH] emacs: call "notmuch tag" only once when archiving a thread
authorAustin Clements <amdragon@MIT.EDU>
Mon, 9 Jan 2012 01:12:59 +0000 (20:12 +1900)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:41:47 +0000 (09:41 -0800)
2e/07e7b5931ea902041bb4a8dcea76c3ac7e375c [new file with mode: 0644]

diff --git a/2e/07e7b5931ea902041bb4a8dcea76c3ac7e375c b/2e/07e7b5931ea902041bb4a8dcea76c3ac7e375c
new file mode 100644 (file)
index 0000000..bca67e9
--- /dev/null
@@ -0,0 +1,109 @@
+Return-Path: <amdragon@mit.edu>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id 493C4414448\r
+       for <notmuch@notmuchmail.org>; Sun,  8 Jan 2012 17:13:02 -0800 (PST)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.7\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5\r
+       tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id MDpvEJOprdSr for <notmuch@notmuchmail.org>;\r
+       Sun,  8 Jan 2012 17:12:57 -0800 (PST)\r
+Received: from dmz-mailsec-scanner-8.mit.edu (DMZ-MAILSEC-SCANNER-8.MIT.EDU\r
+       [18.7.68.37])\r
+       by olra.theworths.org (Postfix) with ESMTP id 7939641444B\r
+       for <notmuch@notmuchmail.org>; Sun,  8 Jan 2012 17:12:49 -0800 (PST)\r
+X-AuditID: 12074425-b7f4a6d0000008e0-a9-4f0a3f109c84\r
+Received: from mailhub-auth-2.mit.edu ( [18.7.62.36])\r
+       by dmz-mailsec-scanner-8.mit.edu (Symantec Messaging Gateway) with SMTP\r
+       id 21.26.02272.01F3A0F4; Sun,  8 Jan 2012 20:12:48 -0500 (EST)\r
+Received: from outgoing.mit.edu (OUTGOING-AUTH.MIT.EDU [18.7.22.103])\r
+       by mailhub-auth-2.mit.edu (8.13.8/8.9.2) with ESMTP id q091Clse002712; \r
+       Sun, 8 Jan 2012 20:12:47 -0500\r
+Received: from awakening.csail.mit.edu (awakening.csail.mit.edu [18.26.4.91])\r
+       (authenticated bits=0)\r
+       (User authenticated as amdragon@ATHENA.MIT.EDU)\r
+       by outgoing.mit.edu (8.13.6/8.12.4) with ESMTP id q091CjUv003302\r
+       (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NOT);\r
+       Sun, 8 Jan 2012 20:12:46 -0500 (EST)\r
+Received: from amthrax by awakening.csail.mit.edu with local (Exim 4.77)\r
+       (envelope-from <amdragon@mit.edu>)\r
+       id 1Rk3nH-0005uz-Oo; Sun, 08 Jan 2012 20:12:59 -0500\r
+Date: Sun, 8 Jan 2012 20:12:59 -0500\r
+From: Austin Clements <amdragon@MIT.EDU>\r
+To: Aaron Ecay <aaronecay@gmail.com>\r
+Subject: Re: [PATCH] emacs: call "notmuch tag" only once when archiving a\r
+       thread\r
+Message-ID: <20120109011259.GD20796@mit.edu>\r
+References: <1325615346-8302-1-git-send-email-jani@nikula.org>\r
+       <m2hb09kj0m.fsf@gmail.com> <87fwftao1b.fsf@nikula.org>\r
+       <m262glk82m.fsf@gmail.com>\r
+MIME-Version: 1.0\r
+Content-Type: text/plain; charset=utf-8\r
+Content-Disposition: inline\r
+Content-Transfer-Encoding: 8bit\r
+In-Reply-To: <m262glk82m.fsf@gmail.com>\r
+User-Agent: Mutt/1.5.21 (2010-09-15)\r
+X-Brightmail-Tracker:\r
+ H4sIAAAAAAAAA+NgFtrEKsWRmVeSWpSXmKPExsUixG6noitgz+Vv8Oksh8W05V/YLZqmO1tc\r
+       vzmT2YHZY+esu+wet+6/Zvd4tuoWcwBzFJdNSmpOZllqkb5dAlfGh72fWAp+cVf0fvvN2MB4\r
+       nrOLkZNDQsBE4uC+LWwQtpjEhXvrgWwuDiGBfYwSPx+8Z4Zw1jNKXJnSzwThnGCSaL09Hyqz\r
+       hFHi4sXNjCD9LAIqEms+9bCA2GwCGhLb9i8Hi4sAxWfPmw9mMwtYSTRs+QBmCwsESXya/Q5s\r
+       N6+AjsSnj6+hNkxjlJg08TMLREJQ4uTMJywQzeoSf+ZdAtrMAWRLSyz/xwERlpdo3jqbGcTm\r
+       BCp51/ILzBYF2jvl5Da2CYzCs5BMmoVk0iyESbOQTFrAyLKKUTYlt0o3NzEzpzg1Wbc4OTEv\r
+       L7VI10IvN7NELzWldBMjODpcVHcwTjikdIhRgINRiYdXwIbLX4g1say4MvcQoyQHk5Iob5gt\r
+       UIgvKT+lMiOxOCO+qDQntfgQowQHs5IIr4AZUI43JbGyKrUoHyYlzcGiJM6rqfXOT0ggPbEk\r
+       NTs1tSC1CCYrw8GhJMHraQfUKFiUmp5akZaZU4KQZuLgBBnOAzQ8AqSGt7ggMbc4Mx0if4pR\r
+       l+N649xzjEIsefl5qVLivPEgRQIgRRmleXBzYEntFaM40FvCvG4gVTzAhAg36RXQEiagJQ/+\r
+       sIMsKUlESEk1MJZGLvN6pS58JOCyYKhi892CUJbFN5dwbOivyF0s3rVko/Lq7/9uWbYo9pyo\r
+       nLc9InG7S573g2zlnR98g7drf/IWfdj0ye7cvh3Mv3PNy49uv13LmrA9rySKs/b576TMdxJH\r
+       ckumcXMxv/vFUfnXVNmEZ7fX9uKN725L+Bop7aruvPb68HbVj0osxRmJhlrMRcWJALJx5wxF        AwAA\r
+Cc: notmuch@notmuchmail.org\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Mon, 09 Jan 2012 01:13:07 -0000\r
+\r
+Quoth Aaron Ecay on Jan 08 at  7:56 pm:\r
+> On Thu, 05 Jan 2012 22:32:16 +0200, Jani Nikula <jani@nikula.org> wrote:\r
+> \r
+> [...]\r
+> \r
+> > In the show view it only modifies the messages that are currently\r
+> > visible. This is to make sure you don't accidentally archive things that\r
+> > have arrived after refreshing the buffer. I think this is safest.\r
+> \r
+> Hmm.  Perhaps it would make sense to add a check in the search view that\r
+> the thread being archived[1] has the same number of messages as it did\r
+> when the buffer was constructed.  (The information on how many messages\r
+> the thread has is in the buffer; we would then compare this to the result\r
+> of “notmuch count thread:000foo” when the user requests to archive.)  If\r
+> the counts don’t match, the interface should show a message in the echo\r
+> area and (probably) refuse to do the tagging.\r
+\r
+That sounds like a clever workaround.\r
+\r
+There's been quite a bit of discussion on fixing this properly.  See,\r
+for example\r
+id:"CAH-f9WsPj=1Eu=g3sOePJgCTBFs6HrLdLq18xMEnJ8aZ00yCEg@mail.gmail.com".\r
+The gist is that we need to include message IDs (or document IDs) in\r
+the search output and use these in tagging operations, rather than the\r
+unstable thread:XXX queries.  Unfortunately, actually fixing this got\r
+stalled since adding this information the text format is a fool's\r
+errand (having been the fool, I can say this!), so we need to switch\r
+Emacs over to using the JSON search format first.  However, once\r
+that's done, it's a relatively simple change.\r