From: Mark Walters <markwalters1009@gmail.com>
To: Michal Sojka <sojkam1@fel.cvut.cz>, notmuch@notmuchmail.org
Subject: Re: [PATCH v2 06/10] cli: Introduce "notmuch address" command
Date: Wed, 05 Nov 2014 12:48:41 +0000 [thread overview]
Message-ID: <87a945ak46.fsf@qmul.ac.uk> (raw)
In-Reply-To: <87y4rpkf8n.fsf@steelpick.2x.cz>
On Wed, 05 Nov 2014, Michal Sojka <sojkam1@fel.cvut.cz> wrote:
> On Wed, Nov 05 2014, Mark Walters wrote:
>> On Tue, 04 Nov 2014, Michal Sojka <sojkam1@fel.cvut.cz> wrote:
>>> On Tue, Nov 04 2014, Mark Walters wrote:
>>>> On Mon, 03 Nov 2014, Michal Sojka <sojkam1@fel.cvut.cz> wrote:
>>>>> This moves address-related functionality from search command to the
>>>>> new address command. The implementation shares almost all code and
>>>>> some command line options.
>>>>>
>>>>> Options --offset and --limit were intentionally not included in the
>>>>> address command, because they refer to messages numbers, which users
>>>>> do not see in the output. This could confuse users because, for
>>>>> example, they could see more addresses in the output that what was
>>>>> specified with --limit. This functionality can be correctly
>>>>> reimplemented for addresses later.
>>>>
>>>> I am not sure about this: we already have this anomaly for output=files
>>>> say. Also I can imagine calling notmuch address --limit=1000 ... to get
>>>> a bunch of recent addresses quickly and I really am wanting to look at
>>>> 1000 messages, not collect 1000 addresses.
>>>
>>> I think that one of the reasons for having the new "address" command is
>>> to have cleaner user interface. And including "anomalies" doesn't sound
>>> like a way to achieve this. I think that now you can use "date:" query
>>> to limit the search.
>>>
>>> I volunteer to implement "address --limit" properly after 0.19. This
>>> should be easy.
>>
>> I think this depends on how you view limit: is it to limit the output
>> (roughly to run "head" on the output), or is to bound the amount of work
>> notmuch has to do (eg to make sure you don't get a long delay). Your
>> suggestion is definitely the former, whereas I am more worried about the
>> latter: limit in your definition could take an essentially unbounded
>> amount of time.
>
> Why? If I understand you correctly, you think of limit in terms of
> messages. There is 1:N mapping between messages and addresses, where
> N >= 1. If I limit the number of printed addresses, I limit the number
> of messages as well. Only if N is zero (which probably can be the case
> with Bcc and --output=recipients) then it can result in unbounded work
> (provided you have infinite number of Bcc only messages in your
> database :-)).
Hi
I was assuming the limit in your scheme would come after the
deduplication: so notmuch would have to find "limit" distinct
addresses. If the limit is applied before the deduping then I agree work
is bounded (in any sane case).
If limit is applied before the deduping then that seems fine.
Best wishes
Mark
>
> Do I miss something?
>
> -Michal
next prev parent reply other threads:[~2014-11-05 12:48 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-03 23:50 [PATCH v2 00/10] "notmuch address" command Michal Sojka
2014-11-03 23:50 ` [PATCH v2 01/10] cli: search: Rename options to context Michal Sojka
2014-11-04 6:24 ` David Bremner
2014-11-03 23:50 ` [PATCH v2 02/10] cli: search: Move more variables into search_context_t Michal Sojka
2014-11-03 23:50 ` [PATCH v2 03/10] cli: search: Convert ctx. to ctx-> Michal Sojka
2014-11-04 6:29 ` David Bremner
2014-11-03 23:50 ` [PATCH v2 04/10] cli: search: Split notmuch_search_command to smaller functions Michal Sojka
2014-11-03 23:50 ` [PATCH v2 05/10] cli: add support for hierarchical command line option arrays Michal Sojka
2014-11-04 6:36 ` David Bremner
2014-11-04 6:38 ` David Bremner
2014-11-03 23:50 ` [PATCH v2 06/10] cli: Introduce "notmuch address" command Michal Sojka
2014-11-04 6:52 ` David Bremner
2014-11-04 9:40 ` Tomi Ollila
2014-11-04 21:59 ` Michal Sojka
2014-11-04 22:12 ` David Bremner
2014-11-04 9:04 ` Mark Walters
2014-11-04 22:15 ` Michal Sojka
2014-11-05 11:22 ` Mark Walters
2014-11-05 12:23 ` Michal Sojka
2014-11-05 12:48 ` Mark Walters [this message]
2014-11-03 23:50 ` [PATCH v2 07/10] cli: search: Convert --output to keyword argument Michal Sojka
2014-11-04 8:58 ` Mark Walters
2014-11-04 9:08 ` Mark Walters
2014-11-04 11:26 ` Michal Sojka
2014-11-03 23:50 ` [PATCH v2 08/10] cli: address: Do not output duplicate addresses Michal Sojka
2014-11-04 7:05 ` David Bremner
2014-11-04 11:36 ` Michal Sojka
2014-11-03 23:50 ` [PATCH v2 09/10] cli: address: Add --output=count Michal Sojka
2014-11-04 9:11 ` Mark Walters
2014-11-03 23:50 ` [PATCH v2 10/10] cli: address: Add --filter-by option to configure address filtering Michal Sojka
2014-11-04 9:23 ` [PATCH v2 00/10] "notmuch address" command Mark Walters
2014-11-04 20:33 ` Tomi Ollila
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://notmuchmail.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87a945ak46.fsf@qmul.ac.uk \
--to=markwalters1009@gmail.com \
--cc=notmuch@notmuchmail.org \
--cc=sojkam1@fel.cvut.cz \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://yhetil.org/notmuch.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).