6.0.0-git
2019-04-25

[#13009] AS sync of IMAP messages that are in trash folder AND in another folder with 'deleted'-flag
Summary AS sync of IMAP messages that are in trash folder AND in another folder with 'deleted'-flag
Queue Synchronization
Queue Version Git master
Type Bug
State Not A Bug
Priority 1. Low
Owners
Requester horde (at) raggi (dot) circinus (dot) uberspace (dot) de
Created 2014-03-04 (1878 days ago)
Due
Updated 2014-03-04 (1878 days ago)
Assigned
Resolved 2014-03-04 (1878 days ago)
Milestone
Patch No

History
2014-03-04 22:17:57 Michael Rubinsky Comment #4 Reply to this comment
1) Ignore the flag. This is basically what you do at the moment, right?
2) Regard messages with this flag as removed.

Do you think that 2) is worth to think about?
No. This causes all kinds of side effects and data integrity issues.
As far as I see, it would work pretty well: If a message is marked 
as deleted, it disappears from synced devices. If an IMAP-client 
undeletes it, in the synced devices it is simply added again...
Either the email is on the client or it's not. Besides the fact that 
we would need to introduce a whole bunch of additional logic to detect 
these changes, there can't be any sort-of-on-the-client-but-hidden 
scenario. We are not going to start to have to track which messages 
are really on the client and which are not.

The "deleted" flag is not honored by ActiveSync clients, period.

2014-03-04 19:54:09 horde (at) raggi (dot) circinus (dot) uberspace (dot) de Comment #3 Reply to this comment

[Show Quoted Text - 10 lines]
First of all, I absolutely agree that this is not an AS bug, sorry for 
posting it as a bug.
I don't know if any specification clarifies the "correct" way of 
moving a message with IMAP (rfc6851 is nowhere implemented, isn't 
it?). To keep a 'deleted' copy of a moved message in the original 
folder is admittedly rather uncommon, but not necessarily a bug.
There is no method available to mark a message as deleted in ActiveSync.
Yes, so here is the problem.
The ONLY way to remove a message from a mailbox on the AS client is 
to send it a remove command. Since this email was not actually 
removed from the mailbox, we cannot do this.
I think here is room for interpretation. I understand your way of 
solving it and, even more, I inwardly prefer it. But the facts are as 
follows: IMAP has the feature of "deleted"-flagged messages, while AS 
lacks it. Hence, we have to analyze the semantics of the 
"deleted"-flag and reproduce this semantics in AS. Two possibilities 
come to my mind:

1) Ignore the flag. This is basically what you do at the moment, right?
2) Regard messages with this flag as removed.

Do you think that 2) is worth to think about? As far as I see, it 
would work pretty well: If a message is marked as deleted, it 
disappears from synced devices. If an IMAP-client undeletes it, in the 
synced devices it is simply added again...

Ideally, the administrator can configure which behavior he likes.
2014-03-04 18:19:08 Michael Rubinsky Comment #2
State ⇒ Not A Bug
Priority ⇒ 1. Low
Reply to this comment
I noticed that there are email clients (at least Apple Mail, 
Mavericks), that, although configured to use the trash folder, leave 
a deleted message in the folder it was deleted from with the 
'deleted'-flag set. As ActiveSync only regards 
Horde_Imap_Client_Base.vanished() mails as removed, such mails 
appear on the syncing devices in both, the original folder and the 
trash, until the mails are expunged.
So, why is this an ActiveSync bug? It's a bug in the client that 
doesn't expunge it from the folder when moving it to the trash. There 
is no method available to mark a message as deleted in ActiveSync. The 
ONLY way to remove a message from a mailbox on the AS client is to 
send it a remove command. Since this email was not actually removed 
from the mailbox, we cannot do this.
2014-03-04 18:03:49 horde (at) raggi (dot) circinus (dot) uberspace (dot) de Comment #1
Type ⇒ Bug
State ⇒ Unconfirmed
Priority ⇒ 2. Medium
Summary ⇒ AS sync of IMAP messages that are in trash folder AND in another folder with 'deleted'-flag
Queue ⇒ Synchronization
Milestone ⇒
Patch ⇒ No
Reply to this comment
I noticed that there are email clients (at least Apple Mail, 
Mavericks), that, although configured to use the trash folder, leave a 
deleted message in the folder it was deleted from with the 
'deleted'-flag set. As ActiveSync only regards 
Horde_Imap_Client_Base.vanished() mails as removed, such mails appear 
on the syncing devices in both, the original folder and the trash, 
until the mails are expunged.

Saved Queries