You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Moggie's main storage format is supposed to be Maildir in an (optionally encrypted) ZIP archive.
I am currently using a fork of pyzipper (see danifus/pyzipper#34 ) for that, it works pretty well under normal operations.
However, I've discovered that if I hard-kill the moggie process while it is in the process of updating the archive, the archive may be left in a state where it has no table-of-contents entry written out and the contents become unusable, effectively lost. For the app's primary storage format, this is an unacceptable bug.
This is a reminder to myself to address this somehow. A few potential ideas:
Review how signal handling is done in the code responsible for updating the archives, make sure we shut down cleanly as often as possible (a moggie change)
Always write out a TOC along with every file added (pyzipper)
Keep older TOCs around (some of the time) and add logic to rediscover them (pyzipper)
Make sure pyzipper knows how to rebuild the table of contents by scanning the archive, and make sure it does so when necessary (pyzipper)
The last of these might be the best option, I think there was already some logic present to do this sort of thing.
The text was updated successfully, but these errors were encountered:
Moggie's main storage format is supposed to be Maildir in an (optionally encrypted) ZIP archive.
I am currently using a fork of pyzipper (see danifus/pyzipper#34 ) for that, it works pretty well under normal operations.
However, I've discovered that if I hard-kill the moggie process while it is in the process of updating the archive, the archive may be left in a state where it has no table-of-contents entry written out and the contents become unusable, effectively lost. For the app's primary storage format, this is an unacceptable bug.
This is a reminder to myself to address this somehow. A few potential ideas:
The last of these might be the best option, I think there was already some logic present to do this sort of thing.
The text was updated successfully, but these errors were encountered: