From mboxrd@z Thu Jan 1 00:00:00 1970 From: marcus-sup@quintic.co.uk (Marcus Williams) Date: Thu, 01 Nov 2007 09:10:26 +0000 Subject: [sup-talk] Seen flag treated incorrectly on IMAP mail In-Reply-To: <2d4a3f900012fe89@IMSS-WIN> References: <2d4a3f900012fe89@IMSS-WIN> Message-ID: <47299802.50007@quintic.co.uk> On 31/10/2007 Colin Bell wrote: > I think its caused by this code in each(...) in imap.rb > > labels = { :Seen => :unread, > :Flagged => :starred, > :Deleted => :deleted > }.inject(@labels) do |cur, (imap, sup)| > cur + (state[:flags].include?(imap) ? [sup] : []) > > This seems (to my non-existent Ruby skills) to be equating the IMAP > Seen flag to be the same as the Sup Unread flag, instead of Seen as > being Not Unread. Yep, I submitted a patch earlier last month (search for imap patch) to fix this although what it did was use the /Recent flag to check for unread messages. This works as long as you dont use the IMAP source in any other client before sup checks for new messages. In reality what it should be checking for is the lack of the /Seen flag. That requires a patch to the sources generally so they can work out if they've been read or not (included in my patch). I've also got some further tweaks to the patch locally that I'll submit once I've tested them a bit more. Marcus