From cb0b632204644f8646877c7e09e08e40b4eeffc7 Mon Sep 17 00:00:00 2001 From: "francois@avalenn.eu" Date: Fri, 6 Nov 2015 11:26:37 +0100 Subject: [PATCH] Re: "notmuch new" does not remove my file from db (double slash problem ?) --- e0/e3aa6ae134663e66c1d4f66e87f75a53306589 | 171 ++++++++++++++++++++++ 1 file changed, 171 insertions(+) create mode 100644 e0/e3aa6ae134663e66c1d4f66e87f75a53306589 diff --git a/e0/e3aa6ae134663e66c1d4f66e87f75a53306589 b/e0/e3aa6ae134663e66c1d4f66e87f75a53306589 new file mode 100644 index 000000000..042460885 --- /dev/null +++ b/e0/e3aa6ae134663e66c1d4f66e87f75a53306589 @@ -0,0 +1,171 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by arlo.cworth.org (Postfix) with ESMTP id 264B86DE1502 + for ; Fri, 6 Nov 2015 12:45:23 -0800 (PST) +X-Virus-Scanned: Debian amavisd-new at cworth.org +X-Spam-Flag: NO +X-Spam-Score: 1.425 +X-Spam-Level: * +X-Spam-Status: No, score=1.425 tagged_above=-999 required=5 tests=[AWL=1.022, + DATE_IN_PAST_06_12=1.103, + RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled +Received: from arlo.cworth.org ([127.0.0.1]) + by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) + with ESMTP id 5WVGvAxFdUij for ; + Fri, 6 Nov 2015 12:45:21 -0800 (PST) +X-Greylist: delayed 1423 seconds by postgrey-1.35 at arlo; + Fri, 06 Nov 2015 12:45:20 PST +Received: from slow1-d.mail.gandi.net (slow1-d.mail.gandi.net [217.70.178.86]) + by arlo.cworth.org (Postfix) with ESMTP id CB3376DE12E8 + for ; Fri, 6 Nov 2015 12:45:20 -0800 (PST) +Received: from relay3-d.mail.gandi.net (relay3-d.mail.gandi.net + [217.70.183.195]) + by slow1-d.mail.gandi.net (Postfix) with ESMTP id 8DD6E48625E + for ; Fri, 6 Nov 2015 21:16:57 +0100 (CET) +Received: from localhost (unknown + [IPv6:2a01:e35:8a40:5f00:1acf:5eff:fe3f:aff1]) + (Authenticated sender: francois@avalenn.eu) + by relay3-d.mail.gandi.net (Postfix) with ESMTPSA id 2C85EA80AD; + Fri, 6 Nov 2015 21:16:52 +0100 (CET) +Date: Fri, 6 Nov 2015 11:26:37 +0100 +From: "francois@avalenn.eu" +To: Tomi Ollila +Cc: notmuch@notmuchmail.org +Subject: Re: "notmuch new" does not remove my file from db (double slash + problem ?) +Message-ID: <20151106102637.GA7384@fjo-extia-HPdeb.example.avalenn.eu> +References: <20150414105720.GH3224@fjo-extia-HPdeb.nsn-net.net> + +MIME-Version: 1.0 +Content-Type: text/plain; charset=iso-8859-1 +Content-Disposition: inline +Content-Transfer-Encoding: 8bit +In-Reply-To: +User-Agent: Mutt/1.5.23.1-rc1 (2014-03-12) +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.20 +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: Fri, 06 Nov 2015 20:45:23 -0000 + +On Tue, Apr 14, 2015 at 04:52:29PM +0300, Tomi Ollila wrote: +> On Tue, Apr 14 2015, francois@avalenn.eu wrote: +> > I have a little problem here. +> > I have a message of which I had multiple copies and I deleted one of +> > them but "notmuch new" does not suppress this copy. +> > +> > $ notmuch search --output=files id:20150216180408.HA14616@myhost +> > /home/francois/Maildir/my_first_box/cur/1424110151_0.24869.myhost,U=742:2,S +> > /home/francois/Maildir/my_second_box/cur/1424110163_0.24869.myhost,U=14486:2,S +> > /home/francois/Maildir/my_third_box//cur/1429004021.3224_3.myhost:2,S +> > +> > The last copy is the one I deleted. +> > I tried to readd the message to this box and after I have this status : +> > +> > $ cp ~/Maildir/my_second_box/cur/1424110163_0.24869.myhost,U=14486:2,S ~/Maildir/my_third_box/cur +> > $ notmuch new +> > Processed 1 file in almost no time. +> > No new mail. +> > $ notmuch search --output=files id:20150216180408.HA14616@myhost +> > /home/francois/Maildir/my_first_box/cur/1424110151_0.24869.myhost,U=742:2,S +> > /home/francois/Maildir/my_second_box/cur/1424110163_0.24869.myhost,U=14486:2,S +> > /home/francois/Maildir/my_third_box/cur/1429004021.3224_3.myhost:2,S +> > /home/francois/Maildir/my_third_box//cur/1429004021.3224_3.myhost:2,S +> > +> > And if I redelete it I come back to beginning : +> > +> > $ rm ~/Maildir/my_third_box/cur/1429004021.3224_3.myhost:2,S +> > $ notmuch new +> > No new mail. Detected 1 file rename. +> > $ notmuch search --output=files id:20150216180408.HA14616@myhost +> > /home/francois/Maildir/my_first_box/cur/1424110151_0.24869.myhost,U=742:2,S +> > /home/francois/Maildir/my_second_box/cur/1424110163_0.24869.myhost,U=14486:2,S +> > /home/francois/Maildir/my_third_box//cur/1429004021.3224_3.myhost:2,S +> > +> > +> > I don't know how the file path with double slash was added in the +> > first place to the DB but I have a real problem with it. +> > +> > Anyone have any idea of how I can solve this ? +> +> When you remoted file from my_third_box/ directory timestamp was updated +> and notmuch new should have noticed file disappearing -- it may be that +> as it has same message id as another it somehow did not get disappeared +> from db. +> +> what you can do is to move all of the messages to another directory, +> run notmuch new, restore (some of) the files and run notmuch new again +> (and then restore tags...) +> +> something like this: +> +> mkdir ~/tmp-20150414 +> notmuch search --output=files id:20150216180408.HA14616@myhost | xargs mv -T ~/tmp-20150414 +> notmuch new +> mv ~/tmp-20150414/1424110151_0.24869.myhost,U=742:2,S ~/Maildir/my_first_box/cur/ +> notmuch new +> +> if you do this, report... + +I finally did this and the result is still the same. + +I think my last chance is to drop completely the notmuch db and +reimporting from dump. + + $ notmuch search --output=files id:20150216180408.GA24515@myhost + /home/francois/Maildir/another_box/cur/1446803446_0.30241.myhost,U=7096:2,S + /home/francois/Maildir/my_second_box/cur/1446803455_0.30241.myhost,U=3407:2,S + /home/francois/Maildir/my_first_box/cur/1446803465_0.30241.myhost,U=32711:2,S + /home/francois/Maildir/my_third_box//cur/1429004021.3224_3.myhost:2,S + $ notmuch search --output=files id:20150216180408.GA24515@myhost | xargs --delimiter="\n" mv -t ~/tmp-$(date +%Y%m%d) + mv: impossible d'évaluer « /home/francois/Maildir/my_third_box//cur/1429004021.3224_3.myhost:2,S »: Aucun fichier ou dossier de ce type + $ ls -ltra ~/tmp-20151106 + total 1576 + -rwxr-xr-x 1 francois francois 453137 nov. 6 10:50 1446803446_0.30241.myhost,U=7096:2,S* + -rwxr-xr-x 1 francois francois 453137 nov. 6 10:50 1446803455_0.30241.myhost,U=3407:2,S* + -rwxr-xr-x 1 francois francois 453137 nov. 6 10:51 1446803465_0.30241.myhost,U=32711:2,S* + drwxr-xr-x 72 francois francois 241664 nov. 6 11:05 ../ + drwxr-xr-x 2 francois francois 4096 nov. 6 11:09 ./ + $ notmuch new + No new mail. + $ notmuch search --output=files id:20150216180408.GA24515@myhost + /home/francois/Maildir/my_third_box//cur/1429004021.3224_3.myhost:2,S + $ mv ~/tmp-20151106/1446803465_0.30241.myhost,U=32711:2,S ~/Maildir/my_first_box/cur/ + « /home/francois/tmp-20151106/1446803465_0.30241.myhost,U=32711:2,S » -> « /home/francois/Maildir/my_first_box/cur/1446803465_0.30241.myhost,U=32711:2,S » + « /home/francois/tmp-20151106/1446803465_0.30241.myhost,U=32711:2,S » supprimé + $ notmuch new + Note: Ignoring non-mail file: /home/francois/Maildir/my_first_box/cur/1444053508_2.8473.myhost,U=29286:2,S + Processed 2 total files in almost no time. + No new mail. + $ ls -ltra "/home/francois/Maildir/my_first_box/cur/1444053508_2.8473.myhost,U=29286:2,S" + -rwxr-xr-x 1 francois francois 26 oct. 5 15:58 /home/francois/Maildir/my_first_box/cur/1444053508_2.8473.myhost,U=29286:2,S* + $ notmuch new + No new mail. + $ notmuch search --output=files id:20150216180408.GA24515@myhost + /home/francois/Maildir/my_first_box/cur/1446803465_0.30241.myhost,U=32711:2,S + /home/francois/Maildir/my_third_box//cur/1429004021.3224_3.myhost:2,S + +The "non-mail file" error is completely unrelated to my problem. It +just occured today when I redid the experiment but was not when I did +it first last week. + + +> > +> > $ notmuch --version +> > notmuch 0.18.2 +> > $ lsb_release -a +> > No LSB modules are available. +> > Distributor ID: Debian +> > Description: Debian GNU/Linux 8.0 (jessie) +> > Release: 8.0 +> > Codename: jessie -- 2.26.2