Christoph Groth <christ...@grothesque.org> writes: > Hello, > > I’m still using a mail setup that involves Gnus with nnimap and a local > dovecot that is run on demand. I sync mail between the local maildir > (that is used by dovecot when it runs) and remote IMAP servers using > isync/mbsync. > > I learned about this setup from Eric Abrahamsen on the ding mailing list > in the old days. I believe that the original presentation of the idea > was this blog post: > > https://web.archive.org/web/20160427162529/http://roland.entierement.nu/blog/2010/09/08/gnus-dovecot-offlineimap-search-a-howto.html > > On the Gnus side, the setup is based on setting nnimap-shell-program to > > "/usr/lib/dovecot/imap -o mail_location=maildir:$HOME/.mail/%s/ > 2>>$HOME/.dovecot.err" > > only that this happens inside a setup involving fancy splitting. (This > way of using dovecot seems to be somewhat obscure, or at least > I haven’t been able to find much documentation about it.) > > Anyway, my setup has been working like this for many years now, but > there’s a wart. Whenever there is new mail and I launch M-x gnus, it > will typically freeze during startup and I have to abort with C-g and > retry. After retrying one or two times Gnus does start and everything > seems to work normally. The new mail is visible in Gnus. > > Here is the kind of the backtrace that I can typically obtain in the > situation > > Debugger entered: ("Quit") > nnimap-wait-for-response(839) > nnimap-get-groups()
I can't really guess why this would be happening. The call to `nnimap-request-scan' should be setting everything up properly, so far as I know. Perhaps someone else will have some better tips for debugging. My only other suggestion would be switching to dovecot as an always-on system service, and then switching Gnus to using "localhost" as the IMAP server address. It seems entirely plausible that that will improve things.