Subject: Re: [sup-devel] Strange maildir/OfflineImap/maildir-sync behavior

From: Roni Choudhury <[email-masked]>
Date: Wed, 19 Jan 2011 13:01:03 -0700

I've noticed this from time to time as well (along with messages not
disappearing, but instead part of the body appearing, then cut off
with a strange error message about how sup can't load the message).  I
find that killing the thread view buffer, then typing @ in index mode
causes these to be fixed.  Just mentioning it because it's easier than
restarting sup, and it may be related to the error you describe.  I'm
also not sure how to file a bug report of that situation.

roni

Excerpts from Edward Z. Yang's message of 2011-01-19 07:08:23 -0700:
> One day, I opened up an old thread to reread an email, and much
> to my dismay, it was GONE!  Instead, there was one of those little
> red flags that Sup sticks on mail that is referenced by other
> threads, but which you don't have a copy of.
> 
> This was a bit bothersome, because no one likes it when their mail mysteriously
> disappears. (It harkens back to a time when I accidentally deleted my entire
> inbox, tried to undo, but Sup crashed in the process and then offlineimap
> decided to sync the changes back to my main account, so I had to restore from
> backup and run with maxage... but that's a story for another time...)
> 
> Some sleuthing, however, revealed that the messages had not disappeared; they
> were still in my Maildir.  And sure enough, when I made Sup repoll the entire
> Maildir (by restarting it), the messages reappeared (along with another 50
> messages that I /swear/ I archived).
> 
> So my question is, why did Sup lose track of the messages?  Did it pick them
> up while they were in new and then OfflineIMAP moved them and they got lost?
> Can I make Sup tell me where it thinks a message should be living on my filesystem
> so I can track these things?  Is this actually OfflineIMAP's fault?
> 
> Cheers,
> Edward
> 
> P.S. Hey Damien, I know you're not planning on working on getting maildir-sync
> merged to master until later this January, but I was wondering if a version of
> the branch rebased on master would be of any use to you.
_______________________________________________
Sup-devel mailing list
[email-masked]
http://rubyforge.org/mailman/listinfo/sup-devel

---

From: "Edward Z. Yang" <[email-masked]>
Date: Thu, 20 Jan 2011 05:53:36 -0500

I have a theory for why this occurs: when we mark mail read on maildir,
it gets moved from new to cur, IIRC? So if Sup's state doesn't get
adequately updated, an old buffer could try to look at the old location.
This should be easily verifiable by looking at the console messages.

Edward

---

From: "Edward Z. Yang" <[email-masked]>
Date: Wed, 19 Jan 2011 15:33:15 -0500

Oh, I know the behavior you're talking about; it's distinct from the
behavior I'm seeing.

What you've mentioned is some curious synchronization bug where if a
new, unread message is available on two buffers (for example, you used
'U'), and you read it from one buffer, it becomes broken on the other
buffer.  That would also be a good one to fix.

Cheers,
Edward

---

From: Damien Leone <[email-masked]>
Date: Wed, 19 Jan 2011 22:12:13 +0100

Sup Edward,

> so I can track these things?  Is this actually OfflineIMAP's fault?

I didn't notice this bug so I have no idea for the moment. :/

> the branch rebased on master would be of any use to you.

Sure! I was maintaining a maildir-sync-master branch on my repository
but it doesn't include the last bunch of commits.

-- 
Damien Leone <[email-masked]>

Web: http://dleone.fensalir.fr/
GPG: 0x82EB4DDF
_______________________________________________
Sup-devel mailing list
[email-masked]
http://rubyforge.org/mailman/listinfo/sup-devel

---

From: Damien Leone <[email-masked]>
Date: Wed, 19 Jan 2011 22:10:20 +0100

Sup guys,

> also not sure how to file a bug report of that situation.

Yes I have noticed this one, it happens to me mainly when I send a
mail then perform a synchronization, probably because the sent mail
gets updated from the SentMail maildir (I use gmail), it's on the
to-fix list.

---

From: "Edward Z. Yang" <[email-masked]>
Date: Wed, 19 Jan 2011 21:55:36 -0500

Ok, I think this behavior is due to an OfflineIMAP bug, or at least
some infelicity.  I think I have squashed it by telling OfflineIMAP
to never ever ever delete files in my Maildir (and also never upload
files from the Maildir to IMAP account: I only want status changes
and deletions to propagate, I'm not spooling mail here--did we ever
get sent mail propagation to work? -- that would be the one case in
which that behavior is desirable).

Cheers,
Edward

---

From: "Edward Z. Yang" <[email-masked]>
Date: Wed, 19 Jan 2011 09:08:23 -0500

Cheers,
Edward