From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 87CDB431FC7 for ; Tue, 29 May 2012 08:00:11 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -2.29 X-Spam-Level: X-Spam-Status: No, score=-2.29 tagged_above=-999 required=5 tests=[RCVD_IN_DNSWL_MED=-2.3, T_MIME_NO_TEXT=0.01] 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 yWPGkRN+zObe for ; Tue, 29 May 2012 08:00:11 -0700 (PDT) Received: from outgoing-mail.its.caltech.edu (outgoing-mail.its.caltech.edu [131.215.239.19]) by olra.theworths.org (Postfix) with ESMTP id 14F82431FBC for ; Tue, 29 May 2012 08:00:11 -0700 (PDT) Received: from fire-doxen.imss.caltech.edu (localhost [127.0.0.1]) by fire-doxen-postvirus (Postfix) with ESMTP id 6EB232E50D8C; Tue, 29 May 2012 08:00:08 -0700 (PDT) X-Spam-Scanned: at Caltech-IMSS on fire-doxen by amavisd-new Received: from finestructure.net (unknown [76.89.192.57]) (Authenticated sender: jrollins) by fire-doxen-submit (Postfix) with ESMTP id 615902E50E2C; Tue, 29 May 2012 08:00:05 -0700 (PDT) Received: by finestructure.net (Postfix, from userid 1000) id 6A850938; Tue, 29 May 2012 08:00:02 -0700 (PDT) From: Jameson Graef Rollins To: Peter Wang , notmuch@notmuchmail.org Subject: Re: search summary and exclusions In-Reply-To: <20120529140107.GE2347@hili.localdomain> References: <20120529000012.GF2331@hili.localdomain> <87mx4sp79z.fsf@servo.finestructure.net> <20120529140107.GE2347@hili.localdomain> User-Agent: Notmuch/0.13+24~g16915cd (http://notmuchmail.org) Emacs/23.4.1 (x86_64-pc-linux-gnu) Date: Tue, 29 May 2012 08:00:00 -0700 Message-ID: <87fwajnibz.fsf@servo.finestructure.net> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" 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: Tue, 29 May 2012 15:00:11 -0000 --=-=-= On Mon, May 28 2012, Peter Wang wrote: > % ./notmuch search --format=json --exclude=true -- thread:0000000000009598 tag:unread > [{"thread": "0000000000009598", > "timestamp": 1338231998, > "date_relative": "Today 05:06", > "matched": 1, > "total": 15, > "authors": "Mark Walters| Peter Wang", > "subject": "[PATCH v6 3/6] cli: make --entire-thread=false work for format=json.", > "tags": ["deleted", "draft", "replied", "sent", "unread"]}] > > Here is a thread I participated in. From this, my MUA displays "1/15", > suggesting that there is 1 unread message out of a total of 15. But > upon opening the thread, there are only 11 messages visible: 4 were > drafts (possibly deleted) which have been excluded. To the user, it > looks like some messages went missing. > > Therefore I would like search --output=summary --exclude=true > to report the total number of non-excluded messages. It doesn't need to > be via the "total" field; a new field would be fine. What you have pasted above is --output=json, not --output=summary. The formats are quite different. What are you asking for a change in? But regardless, I don't think I would like to see the changes you suggest. I would like for the thread total to list the total number of messages in the thread, regardless whether they're excluded or not. Same for the tags. I think I want to continue to see if excluded messages are in a returned thread. The desire to hide the excluded messages in the output is why they're marked as hidden/not visible. Think about the excludes as acting on the search itself, and less on the output. We exclude messages from search, but if they show up in a returned thread we at least acknowledge that they're there. jamie. --=-=-= Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iQIcBAEBCAAGBQJPxORwAAoJEO00zqvie6q84jIP/jpe6C6hDz2rN/KAKgXN8pSk IwbB7r5llVTIgdFQjhgAOcTw9+MTOjFDQzgbUkF5GjrUfbjnMMjKLuLZpvhu0Wvb yg9Wmlf2Y4FmJcWIOlpMLC2yiQadefMtPWreskDzeg5lds6AU/PRBovwSBBDM19S ZzwXFEIFYY3iIpTiGniQL9HrqM2n2X/qJ2dAOlHitls4TXS9tWf4uqICTfaddg0J uzwBWFqkKpT7r2ruGcQ5DQjRi7Vh9dwQxGLIy4jMDeUumaJ5ezHlyFAJfiU3PWa3 KBY3Oy1eVo24rsFagc02bO2dlF9KEPSaxEEmRY3vV2QU1FwbG123YyW2Ednd8Im3 Ob+J86GSa2PJlx/EPdjioqexOMZTeLUYuH6vTxiGAtU2pZRaw5cm3CtQuWU1gPVf ngrx0Rtilxn63pHG11a2TlS8a3Xwjltsy5mcNuA+eC/bmU7G22hfsgUtCeuKnCQ/ mFSdGUHL7OEGZ002Q4WQGRlher8RkNFIxzfEvgIQCoGziJQNChQGYVf2Vg6LDG9I uZxl4BeioZrz/tEIfx4xZUf74Xq0TwThuoqaSQgBDeK2rY3PNuQJM/JxNHT6UbTx S4nXB7KcUYJMbc0Do0Yy4Fj32QBd480I2oZhVf2gvdPHmfNUgoAGu8w9BNDCLf1e +ac5T+t/bCRDjm0EOrEm =1PLn -----END PGP SIGNATURE----- --=-=-=--