<div class="markdown">
<p dir="auto">Benny,<br>
No replies from me in the middle of the night ;-)<br>
MM is now back. First the re-build loop:</p>

<ul>
<li>Yes, I do have rules enabled so that may have been part of the issue.</li>
<li>In my case the error dialog would appear noting an email that could not be found and at the same time the database corruption dialog would appear. They seemed to be independent activities because the DB re-build could be launched and run with the error dialog still up.</li>
<li>When I tried to clear the error dialog, I would get a SBOD that required a Force Quit of MM.</li>
<li>When I eventually looked at the message folders that corresponded to the error, the message ID was not in the folder. Not sure if that meant the emails had been "removed" or what. Interestingly, as I kept re-trying to get out of the loop, the message ID in the error would change.</li>
<li>Now that I have apparently solved the problem by re-downloading from the server, I see that the message folder has the set of messages I saw just before using the re-download approach and then additional messages that have IDs with much higher (say ~2x) numbers. So it did re-download messages that apparently "disappeared". </li>
<li>Since I didn't look at the email library until after trying the cache method of rebuilding, it seems using the cache process must have done something that resulted in messages disappearing?</li>
</ul>

<p dir="auto">As for the original crash, as I noted, this happened when I was adding a third email address to the To line and the potential list of acceptable addresses was partially off-screen, essentially onto my other monitor. I'm not saying the multi-monitor issue was involved because I have had MM crash adding additional addresses to the To list a few times in the past week, like Roland. He might be correct that this is when the additional address (3rd seems right) causes it to add a line. None of the issues you've listed for known DB corruption are in play so this is a new situation. But what was unique was that I had had the crash occur a couple of times and no corruption until the last one with the off-screen situation, but that could be unrelated. I do use DropBox but it's not backing up my Library or Applications. No evidence of a time machine issue but I didn't look to see if it was running. No antivirus software.</p>

<p dir="auto">I'll update to your next version.</p>

<p dir="auto">Rob McClure<br>
sharkez at g</p>

<p dir="auto">On 15 Apr 2014, at 1:16, Benny Kjær Nielsen wrote:</p>

<blockquote>
<p dir="auto">On 14 Apr 2014, at 22:30, Robert McClure wrote:</p>

<p dir="auto">Sorry about the late response. I can see you could have used it earlier on. You'll get a detailed answer instead.</p>

<blockquote>
<p dir="auto">MM crashed earlier (one of a couple of crashes when adding an addressee to the to list) and is now stuck in a loop where it identifies a message it can’t find (I think initially the draft I was working on, but  now I’m not sure) and the option of “do nothing” or do a rebuild (two flavors). I first tried the “from cache” rebuild because I wanted the draft, but that has led to a “find the error” dialog along with a “rebuild” dialog that no matter what, finishes the rebuild and then finds an error.</p>
</blockquote>

<p dir="auto">I recently (last week) experienced this myself (I did not have any or did not understand reports sent to me about this). For me, the problem was that during the rebuild, rules are still active. This is of course not desirable and it was actually a good thing that the result was a broken rebuild-process. Do you have any rules configured?</p>

<p dir="auto">I fixed the bug and then noticed that rebuilding has become extremely slow (not because of the rules). I have seen reports about this, but I had assumed users were just impatient :-) I fixed a performance issue which should make it quite a bit faster (although more improvements could be done).</p>

<p dir="auto">Here is a <a href="http://updates.mailmate-app.com/archives/MailMate_r4174.tbz">direct link</a> to the most recent test version.</p>

<blockquote>
<p dir="auto">Is there a way to get out of this? I have not allowed “download all messages” because I have ~40K messages that is apparently over 3G. I have multiple accounts but this seems to be all related to that one account and draft...</p>
</blockquote>

<p dir="auto">I am of course very interested in the steps needed to reproduce a bug that leads to database corruption.</p>

<p dir="auto">For the record, known database corruption triggers are:</p>

<ul>
<li>The database files were restored from a backup which was created at the same time as MailMate was writing a set of files. There is probably no way to fix that without a complete redesign.</li>
<li>Antivirus software puts a file (email) into quarantine (removing the file just after MailMate saved it). Some comments on that <a href="http://freron.lighthouseapp.com/projects/58672/tickets/666-crash-shortly-after-startup#ticket-666-27">here</a>.</li>
<li>I've had a few reports about hard crashes (as in pulling the plug of the computer) triggering database corruption. Technically (and embarrassingly), I'm not sure exactly what happens, but I assume it is related to low level behavior of the file system.</li>
</ul>

<p dir="auto">The above might sound like MailMate is far from robust, but note that MailMate crashes including <em>force</em> quitting MailMate should, at least in theory, never result in database corruption. Also not, that it is also important that MailMate detects database corruption when it does occur and offers the user a way to fix it which does not involve running along with a database in the “corrupt” state.</p>

<p dir="auto">Please report any issues not related to the items above. Database corruption should, preferably, never happen for most users.</p>

<p dir="auto">-- <br>
Benny</p>

<hr>

<p dir="auto">mailmate mailing list<br>
<a href="mailto:mailmate@lists.freron.com">mailmate@lists.freron.com</a><br>
<a href="http://lists.freron.com/listinfo/mailmate">http://lists.freron.com/listinfo/mailmate</a></p>
</blockquote>

</div>