d.s at daniel.shahaf.name
Tue Sep 20 18:16:48 BST 2011
Sebastian Spaeth wrote on Tue, Sep 20, 2011 at 19:04:26 +0200:
> On Mon, 19 Sep 2011 23:05:08 +0300, Daniel Shahaf wrote:
> > Have you considered stamping a format number somewhere in metadatadir,
> > and have offlineimap check that number before writing anything into that
> > dir?
> > At least that would prevent similar problems going forward (since old
> > versions would see a too-new format number and abort).
> Yeah, that would certainly be a solution, althought the really old
> versions (that are stable in distros now) wouldn't know or care or check
> something like this.
We could change the naming scheme of directories under ~/.offlineimap/.
This will ensure that old versions don't stomp on new versions' metadata,
but I'm not sure whether it'll have any ill effects on old/stable versions.
> But I like the approach and will think if we
> shouldn't adopt it. A "minimum-version-required" field, so to
> say. (actually the sqlite cache database has a db-format version field).
But people can switch between cache backends at will (AIUI), so we can't
use anything specific to the SQLite backend for this purpose.
At Subversion we bump the SQLite 'user_version' whenever we change the
DB schema in an compatible way. We have separate format file guards
when the SQLite DB is just a component of something.
More information about the OfflineIMAP-project