Gnus development mailing list
 help / color / mirror / Atom feed
From: Dave Abrahams <dave@boostpro.com>
To: ding@gnus.org
Subject: Re: `gnus-refer-article-methods' and `gnus-summary-refer-thread'
Date: Sat, 23 Jul 2011 13:16:00 -0400	[thread overview]
Message-ID: <m24o2cvrxr.fsf@pluto.luannocracy.com> (raw)
In-Reply-To: <87fwlxoui2.fsf@andy.bu.edu>


on Sat Jul 23 2011, Andrew Cohen <cohen-AT-andy.bu.edu> wrote:

>>>>>> "Dave" == Dave Abrahams <dave@boostpro.com> writes:
>
>     Dave> on Fri Jul 22 2011, Andrew Cohen <cohen-AT-andy.bu.edu> wrote:
>     >>>>>>> "Dave" == Dave Abrahams <dave@boostpro.com> writes:
>     >> 
>     Dave> It's a bit curious that when I'm sitting on the root of a
>     Dave> thread, `A T' doesn't find the rest of it via nnir when I have
>     Dave> that in `gnus-refer-article-methods'.
>     >> 
>     >> `A T' (gnus-summary-refer-thread) doesn't use
>     >> gnus-refer-article-methods at all. This is distinct from `^`
>     >> (gnus-summary-refer-parent-article) which consults the entries in
>     >> `gnus-refer-article-methods' in order until the parent is found.
>
>     Dave> Right.  Like I said in the part of my post you didn't cite, I
>     Dave> think I understand why it's that way, but it seems like a
>     Dave> programming artifact rather than a design decision.
>
> Finding the parent is finding a single article with a given
> Message-ID. Once found we know to stop. Since gnus has no idea how many
> articles are in a thread it doesn't know when it should stop. 

Oh, but it's an easy single search: the root of the thread is the first
message-ID in the `References' header.  Then you look for anything whose
`Message-ID' matches the root id or whose `References' contains the root
id.  [You could easily make it a bit more thorough in case of broken
threads by making use of more of the contents of `References', but I've
found this to work perfectly well in practice].

> So looping
> through a set of methods doesn't make much sense to me. Instead, we just
> try a single method, which is the search I described. Aside from broken
> mailers, this will find the whole thread within the given group. I'm
> still not entirely clear, but I think your only unhappiness is the
> restriction to searching within the group rather than across all groups
> on the server. Is this right?

Well, as mentioned earlier, I'm only interested in looking in *one*
other group on the server.  But I'd also like to find messages in the
registry and agent if possible (hey, why not ask for the moon, I
figure?).

>     >> The current function adds the found articles from the current
>     >> group into the summary buffer. Nnir creates an ephemeral group
>     >> which can contain articles from multiple groups which is
>     >> substantively different.
>
>     Dave> Yes, but when I use `^' it can use nnir to insert articles
>     Dave> that don't exist in the current group into the current group's
>     Dave> summary buffer... which would is substantively similar to what
>     Dave> I'm asking for ;-)
>
> The problem is that when inserting an article header from a foreign
> group into an existing summary buffer, gnus has no way to keep track of
> where that article came from. It assigns it a phony (negative) article
> number so it knows its not native, but thats it. So every time you try
> to do something with it (like read it), it has to perform the search
> again. 

Oh. I feel unclean. :-P

> This isn't too bad for one or two foreign articles (provided the
> search is fast, which it usually is for retrieving a single article
> with a known message-id), but is horrible if you have a thread with
> many articles in it.

Yuck, I see!

> Nnir does two things, really: it performs queries to find articles
> according to search criteria; and it creates ephemeral groups based on
> these query results.  Searching for messages with a given Message-ID, or
> for messages within the current group, only use the first capability.
>
>     >> Having said that I am just about to check in a modification that
>     >> will allow searching across multiple groups through the use of a
>     >> prefix-arg or setting a variable. Rather than calling the current
>     >> `gnus-summary-refer-thread' this will construct the same imap
>     >> search pattern but use nnir to search across the entire server
>     >> and create an ephemeral group with the results.
>
>     Dave> I'm not yet sure I understand what you're describing.
>
> I think I'm doing what you are asking for: the ability to return a group
> containing all the articles in a thread, even if these articles are
> spread across multiple groups. If I don't have this right, let me know.

I think you have this right.  Although, let me add, if there's no way to
limit which groups on a server are searched it's going to be way too
slow for me (because I have too many groups).

And thanks for all you're doing!

-- 
Dave Abrahams
BoostPro Computing
http://www.boostpro.com




  reply	other threads:[~2011-07-23 17:16 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-22 20:13 Dave Abrahams
2011-07-23  0:20 ` Andrew Cohen
2011-07-23 15:28   ` Dave Abrahams
2011-07-23 16:02     ` Andrew Cohen
2011-07-23 17:16       ` Dave Abrahams [this message]
2011-07-23 17:25         ` Andrew Cohen
2011-07-23 17:33           ` Dave Abrahams
2011-07-29 17:05             ` nnir and agent (was: `gnus-refer-article-methods' and `gnus-summary-refer-thread') Dave Abrahams

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m24o2cvrxr.fsf@pluto.luannocracy.com \
    --to=dave@boostpro.com \
    --cc=ding@gnus.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.
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 NNTP newsgroup(s).