Re: [PATCH] implement a capf for address completion

Subject: Re: [PATCH] implement a capf for address completion

Date: Sun, 11 Aug 2024 20:52:20 -0400

To: Liam Hupfer, David Bremner, notmuch@notmuchmail.org

Cc:

From: Antoine Beaupré


On 2024-08-11 10:36:07, Liam Hupfer wrote:
> Antoine Beaupré <anarcat@debian.org> writes:
>
>> I should have posted a followup to this patch already, and must say it’s
>> really not ready at all.
>>
>> I have found myself in the situation where my address completion is now
>> completely broken. I don’t even *know* how to restore the previous
>> behavior.
>>
>> So clearly, this patch should be ignored for now… But I do feel we
>> should somehow figure out how to hook ourselves in there. There’s
>> probably a way to do some asynchronous thing here, and indeed that’s how
>> even the normal tab completion works, from what I gathered.
>>
>> But this is getting way too deep for me.
>>
>> I will definitely need to look at this again soon though because my
>> stuff is broken, I will try to keep you updated.
>
> As you mentioned upthread, there have been [previous attempts] at this,
> the first of which was by (Emacs household name!) Jonas Bernoulli in
> [[PATCH 0/3] emacs: allow opting out of notmuch’s address completion]. He
> implemented a separate package, available from MELPA and [GitHub -
> tarsius/notmuch-addr: An alternative to notmuch-address.el].
>
> notmuch-addr works great for me with Corfu. Perhaps it can someday ship
> with Notmuch as an alternative to notmuch-address or even replace it
> outright when notmuch moves the minimum supported Emacs version to 27.1.

Oh! This is actually pretty interesting, i didn't realize tarsius made a
standalone package for this...

I have just tested this briefly and it *seems* to work well. For some
reason, the *first* call to it was very slow, with Emacs hanging along
with the message "Collecting email addresses..." in the message
bar... Further calls were near instantaneous even after spawning a new
buffer...

So I'm not sure what to do with this. This certainly seems really
precious stuff! Could we add this to notmuch-emacs, perhaps gated on the
Emacs version?

Running Emacs 29.4 from Debian bookworm-backports here, in case that
matters.

a.
-- 
Dr. King’s major assumption was that if you are nonviolent, if you
suffer, your opponent will see your suffering and will be moved to
change his heart. He only made one fallacious assumption: In order for
nonviolence to work, your opponent must have a conscience. The United
States has none.        - Stokely Carmichael
_______________________________________________
notmuch mailing list -- notmuch@notmuchmail.org
To unsubscribe send an email to notmuch-leave@notmuchmail.org

Thread: