help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Gnus and notmuch


From: Eric Abrahamsen
Subject: Re: Gnus and notmuch
Date: Thu, 10 Jun 2021 14:05:43 -0700
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Alexis Praga <alexis.praga@gmail.com> writes:

> Eric Abrahamsen <eric@ericabrahamsen.net> writes:
>> Well, one problem at a time :)
>>
>> While it should be possible to use a single notmuch installation to
>> search two nnmaildir servers, as you're doing, it's also possible that
>> this is the source of the problem. Could you also show me your
>> ~/.notmuch-config?
>>
>> These two lines are the source of the problem: gnus-search was able to
>> find the article numbers from search hits in the "archive" group, but
>> was not able to turn search hits in the "home.alex.mail.free.archive"
>> group into article numbers. Usually this means it wasn't actually able
>> to locate the files on disk, which usually means there's a mismatch with
>> the 'remove-prefix setting.
>>
>> From the traceback, it looks like you were only searching the
>> nnmaildir+gmail:archive group. Do you have any idea why you were getting
>> results from home.alex.mail.free.archive?
> I don'tt really know why it is searching for the other maildir. That's
> why I have been restarting emacs and removing ~/.newrrc.el*, hoping it
> would resolve some conflict with my previous attempts.

I think see the problem, it's yet more fragility in parsing the output
of search results.

Notmuch is returning all results in all directories, and Gnus filters
out the results it wants depending on which paths match the group name.
Because "archive" is a substring of "home.alex.mail.free.archive", it
thinks it's a relevant search result.

I guess I'm not entirely sure why it fails to find the articles from
that group -- I would expect the articles from the other group to be
located correctly -- but this is probably still the source of the
problem.

This stuff is so fragile that I dread to think of what else might break
with this change, but... If you're comfortable patching and
re-evaluating, would you please apply the attached, then re-evaluate the
`gnus-search-indexed-parse-output' method, and see if that fixes the
problem?

Another proper solution (in addition to this) would be to figure out how
to pass the groups parameter to notmuch in either its folder: or path:
key. That would avoid duplicate work, and presumably run faster. I'll
put this on the todo list.

Eric


Attachment: gnus-search-groups.diff
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]