--- /dev/null
+Return-Path: <jani@nikula.org>\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 14A9D431FC0\r
+ for <notmuch@notmuchmail.org>; Fri, 29 Mar 2013 15:15:12 -0700 (PDT)\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 eeI5IpMfy32n for <notmuch@notmuchmail.org>;\r
+ Fri, 29 Mar 2013 15:15:10 -0700 (PDT)\r
+Received: from mail-la0-f45.google.com (mail-la0-f45.google.com\r
+ [209.85.215.45]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
+ (No client certificate requested)\r
+ by olra.theworths.org (Postfix) with ESMTPS id 5DE81431FAE\r
+ for <notmuch@notmuchmail.org>; Fri, 29 Mar 2013 15:15:10 -0700 (PDT)\r
+Received: by mail-la0-f45.google.com with SMTP id er20so817669lab.32\r
+ for <notmuch@notmuchmail.org>; Fri, 29 Mar 2013 15:15:07 -0700 (PDT)\r
+X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;\r
+ d=google.com; s=20120113;\r
+ h=x-received:from:to:subject:in-reply-to:references:user-agent:date\r
+ :message-id:mime-version:content-type:content-transfer-encoding\r
+ :x-gm-message-state;\r
+ bh=hrD4F1jdX5zjhW5kmFgJooPT/g+pzRC2t7pHQQmAswY=;\r
+ b=e/N3Nthn3gNxZRMRs4GZ+TXlEL7xRlZI76+ivHsUN+WRA7X9ZJFGJWg2cU01fFFZd5\r
+ Hb2Kn01Ax2onhaAN0LfLc5zoPloAiHsI7hv4WcEY7GhWRXdc8KiyGdHlTHfSy09hgo2G\r
+ aI631M8/cqa9YUHZ1oRVmjdLS7SJ6rQo6OScAmRXKUjWXyhCvsUPkQH8h2OSmtlNlw2Y\r
+ 3wQCJlxyF1cdkRKlUuVhdVe3tCOWV6F0kU63Dx4vyOUSTNz3Pri5bJEzVG3+sH3doHIh\r
+ klBiR20bLy57Ox7NGEJuZX3kJ0R93ZzQ0a0U+FOct9Oj+gxvqRaz1CBJ/Hc1tGKwl/M7\r
+ POWA==\r
+X-Received: by 10.152.113.164 with SMTP id iz4mr1795160lab.50.1364595307507;\r
+ Fri, 29 Mar 2013 15:15:07 -0700 (PDT)\r
+Received: from localhost (dsl-hkibrasgw4-50df51-27.dhcp.inet.fi.\r
+ [80.223.81.27])\r
+ by mx.google.com with ESMTPS id z1sm1814128lbk.2.2013.03.29.15.15.05\r
+ (version=TLSv1.2 cipher=RC4-SHA bits=128/128);\r
+ Fri, 29 Mar 2013 15:15:06 -0700 (PDT)\r
+From: Jani Nikula <jani@nikula.org>\r
+To: kedals0@gmail.com, notmuch@notmuchmail.org\r
+Subject: Re: Strange behavior on manually files moving\r
+In-Reply-To: <87vc8me95v.fsf@compaq.home>\r
+References: <87vc8me95v.fsf@compaq.home>\r
+User-Agent: Notmuch/0.15.2+48~gc5630bf (http://notmuchmail.org) Emacs/24.2.1\r
+ (x86_64-pc-linux-gnu)\r
+Date: Sat, 30 Mar 2013 00:15:04 +0200\r
+Message-ID: <87ppyhg8ev.fsf@nikula.org>\r
+MIME-Version: 1.0\r
+Content-Type: text/plain; charset=utf-8\r
+Content-Transfer-Encoding: quoted-printable\r
+X-Gm-Message-State:\r
+ ALoCoQkFj2jCsgQzRRuef7U+TQ6gzJQtG2YKmuk2909dRWbSxXvCkGvC7uPOGCrNebYmY/6tYyer\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: Fri, 29 Mar 2013 22:15:12 -0000\r
+\r
+On Wed, 20 Mar 2013, kedals0@gmail.com wrote:\r
+> Hello,\r
+>\r
+> When I manually move some messages, these changes are detected by\r
+> notmuch but it doesn't remove these files of its database.\r
+> I think, it's more clear to show you an example:\r
+>\r
+> 1) Initialisation\r
+> toto@compaq:~$ notmuch new\r
+> No new mail.\r
+>\r
+> 2) I show you the initial location of the message that we will move\r
+> toto@compaq:~$ ls /home/toto/mail/drafts/cur/#*message*-20130312-16313=\r
+1#:2,DS\r
+> /home/toto/mail/drafts/cur/#*message*-20130312-163131#:2,DS\r
+>\r
+> 3) we move this message\r
+> toto@compaq:~$ mv /home/toto/mail/drafts/cur/#*message*-20130312-16313=\r
+1#:2,DS /home/toto/mail/local/trash/cur/\r
+>\r
+> 4) we update notmuch database\r
+> toto@compaq:~$ notmuch new\r
+> Processed 1 file in almost no time.\r
+> No new mail. Removed 1 message.\r
+>\r
+> 5) we can observe that old message location still exist in the db\r
+> toto@compaq:~$ notmuch search --output=3Dfiles tag:draft folder:local/=\r
+trash/\r
+> /home/toto/mail/local/trash/cur/#*message*-20130312-163131#:2,DS\r
+> /home/toto/mail/drafts/cur/#*message*-20130312-163131#:2,DS\r
+>\r
+> 6) but no file exist at this location.\r
+> toto@compaq:~$ ls /home/toto/mail/drafts/cur/#*message*-20130312-16313=\r
+1#:2,DS\r
+> ls: impossible d'acc=C3=A9der =C3=A0 /home/toto/mail/drafts/cur/#*mess=\r
+age*-20130312-163131#:2,DS: Aucun fichier ou dossier de ce type\r
+>\r
+>\r
+> I don't understand this problem because this usecase is close from a\r
+> file deletion which works.\r
+>\r
+> Would anyone have an idea ?\r
+\r
+What do you have in 'notmuch config get new.ignore'? Have you changed\r
+this setting recently?\r
+\r
+I could reproduce something similar by adding an ignore on a folder that\r
+had files indexed by notmuch:\r
+\r
+$ cd /path/to/maildir\r
+$ mkdir foo\r
+$ mkdir bar\r
+$ # deliver a message to foo/baz\r
+$ notmuch new\r
+Processed 1 file in almost no time.\r
+Added 1 new message to the database.\r
+$ notmuch config set new.ignore foo\r
+$ mv foo/baz bar\r
+$ notmuch new --debug\r
+(D) add_files_recursive, pass 1: explicitly ignoring /path/to/maildir/foo\r
+Processed 1 file in almost no time.\r
+No new mail.\r
+$ notmuch search --output=3Dfiles folder:bar\r
+/path/to/maildir/foo/baz\r
+/path/to/maildir/bar/baz\r
+\r
+Note that the last search finds messages that have at least one\r
+associated file in a folder matching bar, and then outputs *all* the\r
+associated files for the messages. Here, the ignore has caused notmuch\r
+to not notice the file in foo has been deleted.\r
+\r
+\r
+BR,\r
+Jani.\r