Re: [notmuch] [PATCH] Calls to notmuch get queued and executed asynchronously.

Subject: Re: [notmuch] [PATCH] Calls to notmuch get queued and executed asynchronously.

Date: Fri, 21 Oct 2011 22:50:48 +0200

To: James Vasile,


From: Daniel Schoepe

On Tue, 23 Feb 2010 11:32:51 -0500, James Vasile <> wrote:
> Added notmuch-enqueue-asynch to replace calls to
> notmuch-call-notmuch-process.  Calls to notmuch are then queued and
> executed asynchronously.  If the db is busy and we get an error saying
> it was locked, keep trying until the db is no longer busy.  Errors go
> in a buffer as per usual.

I discovered this patch a while ago and it almost applies cleanly (the
conflicts are easy to fix though) and it has made the emacs UI for
notmuch _much_ more responsive and enjoyable for me. As discussed on
IRC, issues such as where to handle retries in case the database is
locked should probably be handled in the notmuch binary instead of each

I am however unaware of any patches to accomplish that and with the pace
of development / patch reviews the way it is at the moment, this patch
is a really helpful stop-gap (performing calls to notmuch asynchronously
is useful independently of where concurrency issues are handled though)
for me. If someone else agrees, I can fix the conflicts for this patch
and send the revised version to the list.

part-000.sig (application/pgp-signature)