notmuchsync default behavior change (was: notmuchsync: handling of the deleted tag)
authorSebastian Spaeth <Sebastian@SSpaeth.de>
Thu, 23 Sep 2010 08:01:54 +0000 (10:01 +0200)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:37:14 +0000 (09:37 -0800)
49/51d78c39bac72e50b44a7e90e7a0f1cf885573 [new file with mode: 0644]

diff --git a/49/51d78c39bac72e50b44a7e90e7a0f1cf885573 b/49/51d78c39bac72e50b44a7e90e7a0f1cf885573
new file mode 100644 (file)
index 0000000..c9136d8
--- /dev/null
@@ -0,0 +1,127 @@
+Return-Path: <Sebastian@SSpaeth.de>\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 D7E6840BFD3\r
+       for <notmuch@notmuchmail.org>; Thu, 23 Sep 2010 01:02:13 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -1.99\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-1.99 tagged_above=-999 required=5\r
+       tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1,\r
+       DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, T_MIME_NO_TEXT=0.01]\r
+       autolearn=ham\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 WaqZtH1bgC3q for <notmuch@notmuchmail.org>;\r
+       Thu, 23 Sep 2010 01:02:03 -0700 (PDT)\r
+Received: from homiemail-a17.g.dreamhost.com (caiajhbdcaid.dreamhost.com\r
+       [208.97.132.83])\r
+       by olra.theworths.org (Postfix) with ESMTP id 4361540BDA1\r
+       for <notmuch@notmuchmail.org>; Thu, 23 Sep 2010 01:02:03 -0700 (PDT)\r
+Received: from homiemail-a17.g.dreamhost.com (localhost [127.0.0.1])\r
+       by homiemail-a17.g.dreamhost.com (Postfix) with ESMTP id 4893C7A8069\r
+       for <notmuch@notmuchmail.org>; Thu, 23 Sep 2010 01:02:03 -0700 (PDT)\r
+DomainKey-Signature: a=rsa-sha1; c=nofws; d=SSpaeth.de; h=from:to:subject\r
+       :in-reply-to:references:date:message-id:mime-version:\r
+       content-type; q=dns; s=sspaeth.de; b=QsitrIoB5FtOtWtYAIgVhBB2IsN\r
+       9nG4QDRk9Ow21/883/JMDSoJmdYHdmuMX1Tvp/b1RdTRLVl873nWs/x/HxAzjJ9x\r
+       sl7nYg94WRJxz7XvKH9Kcky7QCN2ht6vK6hUmk0YoZg+5PDj32FfmMr88Nh4ZWq4\r
+       Gk/84LOjckdAWnHE=\r
+DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=SSpaeth.de; h=from:to\r
+       :subject:in-reply-to:references:date:message-id:mime-version:\r
+       content-type; s=sspaeth.de; bh=y2M2jklouiIGdAZbKBmU795RyIk=; b=c\r
+       HSe4tsgxqBjMWEkTXDkdcm81SN+18l6WUgfA21dvttaadAUWxVB3h0BgMVJ6lLT8\r
+       RdRJXs9pvu50bfVv0qfafCg5y4ui5dxRKSzWui83NznPMdq98ejIerPJrtWZPpjZ\r
+       SL7heZu4g6PKnqh5csb3F/7SfGF3YCxXTRGuS8KOwY=\r
+Received: from spaetzbook.sspaeth.de (mtec-hg-docking-2-dhcp-016.ethz.ch\r
+       [82.130.121.16]) (Authenticated sender: fax@sspaeth.de)\r
+       by homiemail-a17.g.dreamhost.com (Postfix) with ESMTPA id E78E47A805C\r
+       for <notmuch@notmuchmail.org>; Thu, 23 Sep 2010 01:02:01 -0700 (PDT)\r
+Received: by spaetzbook.sspaeth.de (sSMTP sendmail emulation);\r
+       Thu, 23 Sep 2010 10:01:59 +0200\r
+From: Sebastian Spaeth <Sebastian@SSpaeth.de>\r
+To: Notmuch developer list <notmuch@notmuchmail.org>\r
+Subject: notmuchsync default behavior change (was: notmuchsync: handling of\r
+       the deleted tag)\r
+In-Reply-To: <877hie4o1w.fsf@raven.defaultvalue.org>\r
+References: <87bp7vewa5.fsf@raven.defaultvalue.org>\r
+ <87mxrcsb8a.fsf@SSpaeth.de>   <87r5gnomt2.fsf@raven.defaultvalue.org>\r
+ <87zkvb4eiq.fsf@SSpaeth.de>   <877hie4o1w.fsf@raven.defaultvalue.org>\r
+User-Agent: Notmuch/0.3.1-43-g5d515b7 (http://notmuchmail.org) Emacs/23.1.50.1\r
+       (x86_64-pc-linux-gnu)\r
+Date: Thu, 23 Sep 2010 10:01:54 +0200\r
+Message-ID: <87eickhor1.fsf@SSpaeth.de>\r
+MIME-Version: 1.0\r
+Content-Type: multipart/signed; boundary="=-=-=";\r
+       micalg=pgp-sha1; protocol="application/pgp-signature"\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: Thu, 23 Sep 2010 08:02:14 -0000\r
+\r
+--=-=-=\r
+\r
+On 2010-09-22, Rob Browning wrote:\r
+> In general, I think that until/unless notmuchsync can be more assured of\r
+> doing the right thing, and in particular, if the deleted tag is likely\r
+> to become official, notmuchsync should default to not setting it.\r
+> ...or at least, I'd prefer that.  Then I can add --tag-deleted if/when I\r
+> want to.  Of course defaulting to --tag-deleted would also be OK, as\r
+> long as there's a --no-tag-deleted.\r
+\r
+notmuchsync does not want to delete anyones' e-mails by accident and\r
+although I believe that syncing the "deleted" tag should usually be\r
+safe, I can think of situations with multiple copies of a mail where\r
+things could go wrong. I therefore disabled syncing of the maildir flag\r
+"trashed" and the notmuch tag "deleted" by default. It has to be\r
+explicitly be enabled with the new --sync-deleted option.\r
+\r
+Sebastian\r
+\r
+------------------------------------------------------------------\r
+For reference, this could be a szenario where things turn out bad:\r
+\r
+- Send a mail with FCC to your Sent folder and BCC yourself. You have\r
+then 2 mail copies with the same mail id (1 notmuch entry)\r
+\r
+- "Expire" your BCC copy via some mail/webclient, it gets maildir flag\r
+"T"\r
+\r
+- notmuch --revsync will examine new mails and in case the BCC copy is\r
+what notmuch points to, notmuchsync will then add the notmuch tag\r
+"deleted" to that mail id.\r
+\r
+- notmuchsync --prune deletes the BCC mail copy but does not remove the\r
+  "deleted" tag in the notmuch db (it probably should for safety\r
+  reasons).\r
+\r
+- 'notmuch new' will now recognize the BCC copy as removed and point to the\r
+  "Sent/FCC" copy as the current file, but it still carries the "deleted"\r
+  tag for the mail.\r
+\r
+- notmuchsync --prune will happily delete your Sent/FCC copy of the\r
+  mail, or notmuchsync --sync will mark your Sent/FCC copy with the\r
+  "expired" maildir flag.\r
+\r
+--=-=-=\r
+Content-Type: application/pgp-signature\r
+\r
+-----BEGIN PGP SIGNATURE-----\r
+Version: GnuPG v1.4.10 (GNU/Linux)\r
+\r
+iEYEARECAAYFAkybCXIACgkQVYX1jMgnoGKH8gCfZ5/k1+/0djyZwgnxHWvCZHY4\r
+G18An20A3MELeF9mTyOk2aKVpBG2V+J4\r
+=y1tC\r
+-----END PGP SIGNATURE-----\r
+--=-=-=--\r