From c8e5240b544c6a870a28d409607787bad37e39bb Mon Sep 17 00:00:00 2001 From: Austin Clements Date: Mon, 28 Jul 2014 12:24:26 +2000 Subject: [PATCH] Re: [PATCH 04/14] new: Don't report version after upgrade --- bc/475f2ba50102f2dc9a1b192229993b8ba50ce5 | 152 ++++++++++++++++++++++ 1 file changed, 152 insertions(+) create mode 100644 bc/475f2ba50102f2dc9a1b192229993b8ba50ce5 diff --git a/bc/475f2ba50102f2dc9a1b192229993b8ba50ce5 b/bc/475f2ba50102f2dc9a1b192229993b8ba50ce5 new file mode 100644 index 000000000..76ae7ae05 --- /dev/null +++ b/bc/475f2ba50102f2dc9a1b192229993b8ba50ce5 @@ -0,0 +1,152 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by olra.theworths.org (Postfix) with ESMTP id 64519431FB6 + for ; Sun, 27 Jul 2014 09:24:37 -0700 (PDT) +X-Virus-Scanned: Debian amavisd-new at olra.theworths.org +X-Spam-Flag: NO +X-Spam-Score: -2.3 +X-Spam-Level: +X-Spam-Status: No, score=-2.3 tagged_above=-999 required=5 + tests=[RCVD_IN_DNSWL_MED=-2.3] autolearn=disabled +Received: from olra.theworths.org ([127.0.0.1]) + by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) + with ESMTP id QVy2XywitfgS for ; + Sun, 27 Jul 2014 09:24:30 -0700 (PDT) +Received: from dmz-mailsec-scanner-2.mit.edu (dmz-mailsec-scanner-2.mit.edu + [18.9.25.13]) + (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) + (No client certificate requested) + by olra.theworths.org (Postfix) with ESMTPS id C5282431FAE + for ; Sun, 27 Jul 2014 09:24:30 -0700 (PDT) +X-AuditID: 1209190d-f79c06d000002f07-02-53d527beb812 +Received: from mailhub-auth-1.mit.edu ( [18.9.21.35]) + (using TLS with cipher AES256-SHA (256/256 bits)) + (Client did not present a certificate) + by dmz-mailsec-scanner-2.mit.edu (Symantec Messaging Gateway) with SMTP + id 24.5A.12039.EB725D35; Sun, 27 Jul 2014 12:24:30 -0400 (EDT) +Received: from outgoing.mit.edu (outgoing-auth-1.mit.edu [18.9.28.11]) + by mailhub-auth-1.mit.edu (8.13.8/8.9.2) with ESMTP id s6RGOSr6016595; + Sun, 27 Jul 2014 12:24:29 -0400 +Received: from awakening.csail.mit.edu (awakening.csail.mit.edu [18.26.4.91]) + (authenticated bits=0) + (User authenticated as amdragon@ATHENA.MIT.EDU) + by outgoing.mit.edu (8.13.8/8.12.4) with ESMTP id s6RGORcp014954 + (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NOT); + Sun, 27 Jul 2014 12:24:28 -0400 +Received: from amthrax by awakening.csail.mit.edu with local (Exim 4.80) + (envelope-from ) + id 1XBRFK-00071D-NH; Sun, 27 Jul 2014 12:24:26 -0400 +Date: Sun, 27 Jul 2014 12:24:26 -0400 +From: Austin Clements +To: Mark Walters +Subject: Re: [PATCH 04/14] new: Don't report version after upgrade +Message-ID: <20140727162426.GF13893@mit.edu> +References: <1406433173-19169-1-git-send-email-amdragon@mit.edu> + <1406433173-19169-5-git-send-email-amdragon@mit.edu> + <87y4vfywmp.fsf@qmul.ac.uk> +MIME-Version: 1.0 +Content-Type: text/plain; charset=us-ascii +Content-Disposition: inline +In-Reply-To: <87y4vfywmp.fsf@qmul.ac.uk> +User-Agent: Mutt/1.5.21 (2010-09-15) +X-Brightmail-Tracker: + H4sIAAAAAAAAA+NgFmpileLIzCtJLcpLzFFi42IR4hRV1t2nfjXYYP9jXovVc3ksrt+cyezA + 5LFz1l12j2erbjEHMEVx2aSk5mSWpRbp2yVwZSw79oCp4LRkxf0NB5kaGJeLdDFyckgImEhs + /b2ZHcIWk7hwbz1bFyMXh5DAbCaJFZPXsUA4Gxkl1lz/A+WcZpKYvXUdWIuQwBJGiS9PM0Fs + FgFVid2/m1lAbDYBDYlt+5czgtgiAjoStw8tAKtnFpCW+Pa7mQnEFhZwktg9fRVQnIODF6jm + 7vQoiPlTGSWmbn7HBlLDKyAocXLmExaIXi2JG/9eMoHUg8xZ/o8DJMwJtGr3+rVgJaICKhJT + Tm5jm8AoNAtJ9ywk3bMQuhcwMq9ilE3JrdLNTczMKU5N1i1OTszLSy3SNdLLzSzRS00p3cQI + DmpJ3h2M7w4qHWIU4GBU4uHNYLsSLMSaWFZcmXuIUZKDSUmUt0v1arAQX1J+SmVGYnFGfFFp + TmrxIUYJDmYlEd7Ct0DlvCmJlVWpRfkwKWkOFiVx3rfWVsFCAumJJanZqakFqUUwWRkODiUJ + 3vNqQEMFi1LTUyvSMnNKENJMHJwgw3mAhs8AWcxbXJCYW5yZDpE/xagoJc7bAdIsAJLIKM2D + 64UlnVeM4kCvCPOGglTxABMWXPcroMFMQINZ/C+DDC5JREhJNTB2NlQbPNi5OdJzrUhW4zwR + sxNlfHME2Na8XHR6Z9YboTVL4mrcGH+Ft7Jx/ZXeyrr9x5ENKbwL/z6bPTW3N2mGiraZiVuE + 4ZK4u+kbN13veiiWUBztxzNl0a9ih/CPGZEpL140BdfP0/3y3FaotJh7+1yFFutnJ12fq0af + kzyWuTKs7ETf92AlluKMREMt5qLiRACxHkqzFQMAAA== +Cc: notmuch@notmuchmail.org +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.13 +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, 27 Jul 2014 16:24:37 -0000 + +Quoth Mark Walters on Jul 27 at 10:33 am: +> On Sun, 27 Jul 2014, Austin Clements wrote: +> > The version number has always been pretty meaningless to the user and +> > it's about to become even more meaningless with the introduction of +> > "features". Hopefully, the database will remain on version 3 for some +> > time to come; however, the introduction of new features over time in +> > version 3 will necessitate upgrades within version 3. It would be +> > confusing if we always tell the user they've been "upgraded to version +> > 3". If the user wants to know what's new, they should read the news. +> +> Two thoughts on this: +> +> first, we could print the names of the new features here to make it +> easier for the user to find them in NEWS. + +Interesting. Transparency is good, though I worry that this would +expose the user to internal implementation details (certainly some +features will translate to user-visible features, but others will be +entirely internal to the library). + +> Secondly, would it be worth having something like notmuch +> --database-version or similar which prints the features? If I understand +> the series then notmuch clients don't necessarily need to upgrade the +> database unless they want the new features. This means that knowing what +> version they are running might not tell us which features they have +> enabled (which could make debugging difficult) + +Good idea, though I'd be inclined to do it in a follow-up series just +so this series doesn't get even longer. It won't be a problem for +now: this series doesn't touch our current policy of unconditionally +upgrading on notmuch new (a policy I think we should keep, though +that's a separate discussion) so the notmuch version should still tell +us the database version/features. + +> Best wishes +> +> Mark +> +> > --- +> > notmuch-new.c | 3 +-- +> > test/T530-upgrade.sh | 2 +- +> > 2 files changed, 2 insertions(+), 3 deletions(-) +> > +> > diff --git a/notmuch-new.c b/notmuch-new.c +> > index d269c7c..b7590a8 100644 +> > --- a/notmuch-new.c +> > +++ b/notmuch-new.c +> > @@ -1023,8 +1023,7 @@ notmuch_new_command (notmuch_config_t *config, int argc, char *argv[]) +> > add_files_state.verbosity >= VERBOSITY_NORMAL ? upgrade_print_progress : NULL, +> > &add_files_state); +> > if (add_files_state.verbosity >= VERBOSITY_NORMAL) +> > - printf ("Your notmuch database has now been upgraded to database format version %u.\n", +> > - notmuch_database_get_version (notmuch)); +> > + printf ("Your notmuch database has now been upgraded.\n"); +> > } +> > +> > add_files_state.total_files = 0; +> > diff --git a/test/T530-upgrade.sh b/test/T530-upgrade.sh +> > index 7d5d5aa..c4c4ac8 100755 +> > --- a/test/T530-upgrade.sh +> > +++ b/test/T530-upgrade.sh +> > @@ -33,7 +33,7 @@ test_expect_equal "$output" "\ +> > Welcome to a new version of notmuch! Your database will now be upgraded. +> > This process is safe to interrupt. +> > Backing up tags to FILENAME +> > -Your notmuch database has now been upgraded to database format version 2. +> > +Your notmuch database has now been upgraded. +> > No new mail." +> > +> > test_begin_subtest "tag backup matches pre-upgrade dump" -- 2.26.2