On Thu, Oct 07 2010, Lars Magne Ingebrigtsen wrote: >> Maybe 100 is not enough actually? >> How others MUA plays with that? > > The only way to get the flags data (without QRESYNC) is to say "UID > FETCH FLAGS 1:*". If you have 200K messages in that group, it'll take a > while. > > When all IMAP servers get QRESYNC support this will be a moot issue, but > at present you have to trade off accuracy for speed in this area. I > think other MUAs do opportunistic FLAGS sync in the background. I took a look a mutt, and from what I understand it does 2 things: - to know if there's new mail, it uses the STATUS command. . STATUS INBOX (UIDNEXT UIDVALIDITY UNSEEN RECENT MESSAGES) * STATUS "INBOX" (MESSAGES 11790 RECENT 0 UIDNEXT 26293 UIDVALIDITY 1247083159 UNSEEN 1) That seems enough to use for 'g'. - Store the UIDVALIDITY value permanently for each mailbox, and whenever it changes refetch all information for all mails in that mailbox. That sounds safer than the current behaviour, and probably not complicated to implement. WDYT Lars? :) -- Julien Danjou // ᐰ http://julien.danjou.info