spaetz/offlineimap — Issue #15: Improve 1-way syncing usability
Author: spaetz
Created: 2012-01-08 01:12:23+00:00
State: open
Labels: Feature

The readonly feature goes a long way towards true 1-way syncing, but it does not guarantee flawless operation in itself.

Imagine the LOCAL is readonly = True and you have folders F1, F2, F3 on REMOTE and F2, F3 on LOCAL.

A sync will lead to an error message that it tried to get nonexisting folder F1 (on local). It a) prevented F1 from being created on LOCAL and REM:F1 attempts to get it's corresponding Partner LOC:F1 before it would determine that there is None.

This piece loads the local folder, so when getfolder() fails with an Exception because the local folder does not exist, we should exit gracefully and log something nice.

accounts.py.363:
# Load local folder.
localfolder = localrepos.\
getfolder(remotefolder.getvisiblename().\
replace(remoterepos.getsep(), localrepos.getsep()))