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 A0D5F6DE1405 for ; Sun, 23 Aug 2015 13:43:43 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at cworth.org X-Spam-Flag: NO X-Spam-Score: -2.282 X-Spam-Level: X-Spam-Status: No, score=-2.282 tagged_above=-999 required=5 tests=[AWL=0.569, RCVD_IN_DNSWL_MED=-2.3, RP_MATCHES_RCVD=-0.55, SPF_PASS=-0.001] 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 nZul-DAygMvv for ; Sun, 23 Aug 2015 13:43:42 -0700 (PDT) Received: from market.scs.stanford.edu (market.scs.stanford.edu [171.66.3.10]) by arlo.cworth.org (Postfix) with ESMTPS id 008C86DE13FE for ; Sun, 23 Aug 2015 13:43:41 -0700 (PDT) Received: from market.scs.stanford.edu (localhost.scs.stanford.edu [127.0.0.1]) by market.scs.stanford.edu (8.14.7/8.14.7) with ESMTP id t7NKhc77026522; Sun, 23 Aug 2015 13:43:38 -0700 (PDT) Received: (from dm@localhost) by market.scs.stanford.edu (8.14.7/8.14.7/Submit) id t7NKhc7a030300; Sun, 23 Aug 2015 13:43:38 -0700 (PDT) X-Authentication-Warning: market.scs.stanford.edu: dm set sender to return-ph3ayavez28xe94sjqm2b6vw8e@ta.scs.stanford.edu using -f From: David Mazieres To: Amadeusz =?utf-8?B?xbtvxYJub3dza2k=?= , notmuch@notmuchmail.org Subject: Re: muchsync files renames In-Reply-To: <87oahxojlv.fsf@ta.scs.stanford.edu> References: <878u93ujdo.fsf@freja.aidecoe.name> <876146o920.fsf@ta.scs.stanford.edu> <871teu8kdd.fsf@freja.aidecoe.name> <87oahxojlv.fsf@ta.scs.stanford.edu> Reply-To: David Mazieres expires 2015-11-21 PST Date: Sun, 23 Aug 2015 13:43:37 -0700 Message-ID: <87lhd1ohvq.fsf@ta.scs.stanford.edu> MIME-Version: 1.0 Content-Type: text/plain X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.18 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: Sun, 23 Aug 2015 20:43:43 -0000 So just to follow up a bit. I looked into things a bit further, and here is what I found with maildir.synchronize_flags set to true. Initially, when you run "muchsync --init", it copies all the files to your maildir, and for each file invokes notmuch_message_tags_to_maildir_flag. That changes the name of the file, with the result that the sql database and the actual mail directory end up out of sync. That on it's own is not a big deal, but it means that the next time muchsync, muchsync will have to rescan all of the files, as their names are no longer correct. That shouldn't cause any extra traffic between the two machines, but it will require time on the client. That is likely the source of the delay you were seeing. However, if you C-c the client during this process, I still don't see any problems arising that cause more links to be transferred between machines. So I'm kind of stumped about that part. Maybe muchsync should create the original file name based on tags, so as to avoid having to rescan in the common case. I wish there were some way of getting the renamed file after notmuch_message_tags_to_maildir_flags. David