[Users] [Enhancement] Clear selection when IMAP message is no longer available

nvx nvx2004 at hotmail.com
Tue May 3 18:32:19 CEST 2016

I often access my IMAP mail account via multiple devices at the same
time (office computer, mobile phone, ...). As such, it often happens to
me that when I keep the Inbox folder selected, new messages are
automatically previewed by Claws Mail and thus marked as read.

My setup:
- Default selection: last opened message, none
- View message on selection: if preview pane is visible
- Open Inbox when new messages are available: disabled
- Preview pane visible: yes
- Mark message as read after: 0 seconds

Therefore: when a message is selected in the Inbox and during a periodic
mail check Claws Mail finds that this message is no longer
available (e.g. because it has been deleted/moved via another device)
but new message(s) are available, the original selection is retained
and hence one of the new messages is automatically selected and
previewed. This, consequently, marks the message as read.

What I would suggest here is to clear the selection if Claws Mail finds
during mail check that the selected message is no longer
available. This would then prevent auto-selecting any of the new
messages, previewing them, and, ultimately, none of them would be
marked as read.

Steps to reproduce:
1. Set up an IMAP account & enable preview pane. Set "View message on
selection" to "If preview pane is visible" and "Mark message as read
after" to "0 seconds".
2. Clear all messages from Inbox & keep Inbox opened.
3. Send one message to the respective account and wait until it has
been received by Claws Mail. Select the message to preview it.
4. Disable periodic mail check (just to make sure that steps 5 & 6 are
carried out before the next mail check).
5. Delete the IMAP message using another client (mobile phone/...).
6. Send a second message to the respective account.
7. Enable periodic mail check in Claws Mail and wait until mail is
8. When Claws Mail checks the IMAP Inbox, it deletes the first message
which is no longer available and downloads the second, new message.
However, because previously the first message was selected, the new
(second) message becomes immediately selected as well and hence marked
as read.

OS & application info:
Ubuntu 16.04 x64
Claws mail 3.13.2

More information about the Users mailing list