unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
From: Michael Hudson-Doyle <michael.hudson@canonical.com>
To: notmuch@notmuchmail.org
Subject: notmuch reply From:-guessing heuristics
Date: Fri, 09 Dec 2011 10:53:04 +1300	[thread overview]
Message-ID: <8762hq7mtb.fsf@canonical.com> (raw)

Hi all,

I have a specific example where "notmuch reply" does not set a useful
from: header.  The set is:

1) I have a google apps-for-your-domain address,
   michael.hudson@linaro.org

2) There is a group/alias, validation@linaro.org that only accepts mail
   from members

3) michael.hudson@linaro.org forwards to michael.hudson@canonical.com,
   from where I get email with offlineimap.

4) michael.hudson@linaro.org and michael.hudson@canonical.com are both
   configured as addresses in ~/.notmuch-config with the linaro.org
   address being primary.

When I reply to a mail to validation@linaro.org, the guessed address is
michael.hudson@canonical.com and unless I change it, the reply bounces,
which is obviously a bit annoying.

Looking at the headers (and the notmuch source),
michael.hudson@canonical.com seems to be being found in the Received
headers.  michael.hudson@linaro.org is not in any Received header, which
is a bit strange, but in any case I think the code would find
michael.hudson@canonical.com first (would it perhaps make more sense to
search backwards through received?  An earlier header is probably closer
to what was intended, in some sense).

michael.hudson@linaro.org does appear in a Delivered-To: header, so
maybe those could be considered (it seems that some MTAs add a
Delivered-To header from the envelope address, so it would have some
legitimacy)?  It would work in this case, but only because the
Delivered-To that the canonical.com MTA adds is an internal address
that's not configured as an address for me in notmuch...

Alternatively, *I* wouldn't mind if notmuch stopped trying at all hard,
and just used the primary address if there was nothing matching in
to:/cc: but I guess that wouldn't work on mailing lists at all...

Hm, I guess I've argued myself around to thinking that considering
Delivered-To as a source of potential from addresses would be an
improvement.  What do you guys think?

Cheers,
mwh

                 reply	other threads:[~2011-12-08 21:53 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=8762hq7mtb.fsf@canonical.com \
    --to=michael.hudson@canonical.com \
    --cc=notmuch@notmuchmail.org \
    /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).