deltachat-core-rust icon indicating copy to clipboard operation
deltachat-core-rust copied to clipboard

feat: Don't mark messages as seen on IMAP if bcc_self=0 or bot=1

Open iequidoo opened this issue 3 months ago • 1 comments

bcc_self=0 means that the user disabled it or it's a chatmail setup with the only device and w/o backups. If a backup is made someday, old messages not marked as IMAP-seen aren't a problem and new ones are marked as IMAP-seen.

For bots, particularly multi-device ones (which are a rare case), probably no sane logic can be built on the "seen" message status. Moreover, if the user has additionally a bot that reads incoming messages, it doesn't mean that the user doesn't want to read them too.

Also don't mark a message as IMAP-seen just if it already exists on the device as this doesn't mean that it exists on another device.

Also don't mark MDNs and DSNs as IMAP-seen. Marking MDNs as seen is useless, they shouldn't be displayed by any MUA. Auto-marking DSNs as seen should be avoided because the user may want to see them in another MUA.

iequidoo avatar Sep 14 '25 08:09 iequidoo

test_markseen_message_and_mdn fails and it has a comment:

# Please only change this test if you are very sure that it will still catch the issues it catches now.
# We had so many problems with markseen, if in doubt, rather create another test, it can't harm.

Probably this means that MDNs must be marked as \Seen for some reason which is not documented unfortunately. ... 53fed91a174876957e37848e7621e1ef0b19464f (Fix marking read receipts as seen) added this test . ... I still decided to modify the test. But if MDNs are marked as seen currently for a good reason, i'll revert this part of the PR. CC @Hocuri

iequidoo avatar Sep 15 '25 10:09 iequidoo