ProtonMail / proton-bridge

Proton Mail Bridge application
GNU General Public License v3.0
1.15k stars 156 forks source link

IMAP flag updates are sometimes not synced #469

Open jknockaert opened 6 months ago

jknockaert commented 6 months ago

I noticed that with recent versions of Bridge (since 3.9 or earlier) sometimes message IMAP flag updates (\Seen, \Flagged etc) are not properly synced. I couldn't exactly figure out what triggers the issue, but it seems to happen in a setup where one Bridge installation is already synced and a second Bridge installation is syncing the same account. If a flag is changed using the first installation (e.g. messages marked as read) while the second installation is in the process of syncing, the second installation will never pick up the flag change.

Am using Bridge on macOS.

LBeernaertProton commented 6 months ago

Hey @jknockaert , this is currently expected. While syncing we only allow certain events to be applied. Once the sync process completes the mail state will catch up.

jknockaert commented 6 months ago

@LBeernaertProton The problem seems to be that (in some cases) the second installation never catches up on the flag updates applied through the first installation while the second installation was in the process of syncing.

LBeernaertProton commented 6 months ago

Could you share the logs of the second machine? It would be great if it captures the whole syncing process and a couple of min after the sync has completed.

jknockaert commented 6 months ago

OK will try to post the logs next time this happens.

LBeernaertProton commented 6 months ago

We were unable to reproduce this locally.

jknockaert commented 6 months ago

Yesterday again I noticed that on one installation (of Bridge) a message was synced as "unread" whereas it was marked as read in all other installations (bridge and native apps). This didn't update automatically. Then when I today marked it as "read" in the first installation (in order to sync it manually) the instance of Bridge crashed. Unfortunately nothing of any use in the logs.