Hi, I'm using nnimap with a Courier IMAP server (some version from 2004), and expiry is taking longer and longer; currently exiting my INBOX (with article numbers in the 6500s, perhaps half of those occupied by actual articles) takes about 30 seconds. A friend pointed me to , which hints that Courier's UID SEARCH implementation is sometimes slow. What Gnus is sending to Courier is something like UID SEARCH UID 6512:6513,6515,6519,6526:6528 NOT SINCE 19-Oct-2005 and giving such commands by hand results in a long wait. In comparison, the commands UID SEARCH NOT SINCE 19-Oct-2005 UID SEARCH SINCE 19-Oct-2005 are almost instantaneous. So it seems that Courier is doing something very suboptimal with the Gnus command. The attached patch (against 5.10.6) seems to have helped: now exiting the INBOX summary takes something like 2 seconds instead of the previous 30. I'm not very intimate with Emacs Lisp, Gnus or IMAP, so somebody should probably check the code (and it looks like nnimap-request-expire-articles could use some refactoring). However, it seems to have worked correctly for me in the, um, three times I've exited a summary buffer this far. -- Jouni K Seppänen