Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sync should only download subscribed folders (LSUB) #120

Open
netandreus opened this issue Mar 19, 2020 · 1 comment
Open

Sync should only download subscribed folders (LSUB) #120

netandreus opened this issue Mar 19, 2020 · 1 comment

Comments

@netandreus
Copy link
Contributor

netandreus commented Mar 19, 2020

Describe the bug
As we discuss in #105 there is a problem with syncing Exchange mailboxes. There are many clients of Microsoft Office365 mail system, and I think it is important. Problem occurs when we sync folders like "Archive" e.t.c.

To Reproduce
Steps to reproduce the behavior:

  1. Add Microsoft Office365 mail account.
  2. Try to sync it
  3. See errors
[19-Mar-20 11:54:04] DEBUG: No messages to delete in Archive
[19-Mar-20 11:54:04] ERROR: cannot read - connection closed?

Also when we try to sync folder "Calendar/United States holidays" in database added this messages:

**Message.subject**
Retrieval using the IMAP4 protocol failed for the following message: 367

**Message.text_plain**
The server couldn't retrieve the following message:

Subject: "Juneteenth"
From: "xxxx" ("/O=EXCHANGELABS/OU=EXCHANGE ADMINISTRATIVE GROUP (FYDIBOHF23SPDLT)/CN=RECIPIENTS/CN=D6FFC709A0FE4E2F8AD251C6DE637AAD-ADMIN")
Sent date: 9/21/2019 9:00:25 PM

Expected behavior
Correctly folders sync.

Possible solution
As we decide it should be mechanism to per-account select folders to sync. And this mechanism already exists - it is "folder subscriptions". But it has one disadvantage. Folders "INBOX" and "Outbox" by default are unsubscribed and Outlook client synced it ignoring subscriptions.

unsubscribed_but_displayed

So we need to set mandatory_sync_folders parameter somewhere (for example in default.ini / local.ini).
It also needed parameter sync_only_subscribed_folders, which will be regulate behavior of this functionality. Default sync_only_subscribed_folders = false for current behavior.

Requirements
I have already done some work with required libraries. You just need to review it :)

@netandreus
Copy link
Contributor Author

I finish this work @mikegioia Please review my pull request #121

@mikegioia mikegioia changed the title Sync only subscribed folders Sync should only download subscribed folders (LSUB) Mar 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants