all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Michael Heerdegen <michael_heerdegen@web.de>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: 31057@debbugs.gnu.org
Subject: bug#31057: 27.0.50; Gnus: Make configurable what to show when selecting a group
Date: Fri, 13 Apr 2018 14:16:16 +0200	[thread overview]
Message-ID: <87lgdrpai7.fsf@web.de> (raw)
In-Reply-To: <87bmeovaea.fsf@mouse.gnus.org> (Lars Ingebrigtsen's message of "Thu, 12 Apr 2018 15:09:49 +0200")

Lars Ingebrigtsen <larsi@gnus.org> writes:

> I see.  I'm not familiar with the way nadvice works at all.

You should definitely have a look!

> Have you checked that the list of articles that's finally returned is
> the one you expect?

Yes, I think so.


> Try edebugging through gnus-select-newsgroup to see whether there's
> anything there that removes the list you've returned (if you've
> returned it. :-)).

Hmm - ehhm - it suddenly works as expected!

But I did not change anything in my config.  I switched from emacs-26 to
master since my report, and the registry corruption has been fixed -
dunno if that made the difference.

So, I guess you can close this report.  I can reopen it when the issue
reappears.


For the record, I changed my code to

#+begin_src emacs-lisp
(add-function :around gnus-alter-articles-to-read-function
              (defun my-gnus-auto-show-registry-marked (f group-name article-list)
                (cl-union
                 (delq nil
                       (mapcar (lambda (id) (cdr (gnus-request-head id group-name)))
                               (cl-loop for key being the hash-keys of (oref gnus-registry-db data)
                                        using (hash-values v)
                                        when (cdr (assoc 'mark v))
                                        collect key)))
                 (funcall f group-name article-list))))
#+end_src

to look at the cdr of (assoc 'mark v) because when you delete a custom
mark, this leaves over an association like (Note) for me, which the
first version I had posted erroneously interpreted as "custom mark
present".


Thanks,

Michael.





  reply	other threads:[~2018-04-13 12:16 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-04 10:55 bug#31057: 27.0.50; Gnus: Make configurable what to show when selecting a group Michael Heerdegen
2018-04-11 20:47 ` Lars Ingebrigtsen
2018-04-12  9:34   ` Michael Heerdegen
2018-04-12 11:40     ` Lars Ingebrigtsen
2018-04-12 12:26       ` Michael Heerdegen
2018-04-12 13:09         ` Lars Ingebrigtsen
2018-04-13 12:16           ` Michael Heerdegen [this message]
2018-04-13 12:33             ` Lars Ingebrigtsen

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=87lgdrpai7.fsf@web.de \
    --to=michael_heerdegen@web.de \
    --cc=31057@debbugs.gnu.org \
    --cc=larsi@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.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.