Re: [PATCH] lib: consider all instances of Delivered-To header

Subject: Re: [PATCH] lib: consider all instances of Delivered-To header

Date: Mon, 28 Jun 2021 10:11:32 +0300

To: David Bremner, notmuch@notmuchmail.org

Cc:

From: Hannu Hartikainen


Thanks for the review! Please consider the patch obsolete, I'll submit a
v2 later with the comments addressed.

On Sat, 26 Jun 2021 14:36:23 -0300, David Bremner <david@tethera.net> wrote:
> Hannu Hartikainen <hannu@hrtk.in> writes:
> > +	 * Similarly, multiple instances of Delivered-To may be present. We
> > +	 * concatenate them so the one with highest priority may be picked.
> >  	 */
> 
> Highest priority seems a bit vague here. Do you mean most recent?

I mean that the address configured as `primary_email` is chosen over
those configured as `other_email` if both are present. Basically, let
`user_address_in_string` in notmuch-reply.c do its thing. AFAICT the
addresses in `other_email` are checked in sequence so the first matching
one is chosen, ie. they also have a priority. Not sure if that is
intended and documented or if it could change later, so I didn't want to
go into specifics in the comment.

> The idiomatic (for notmuch) thing to do for a bug fix is first to add a
> test with "test_subtest_known_broken", then to remove that line in the
> commit you fix the bug.

So it's best to have a commit with only the (broken) test first as
opposed to adding the fix and the test in the same commit? Ok, I'll do
that.

Hannu
_______________________________________________
notmuch mailing list -- notmuch@notmuchmail.org
To unsubscribe send an email to notmuch-leave@notmuchmail.org

Thread: