YorbaApplication's 'exiting' signal now allows callbacks to cancel the
edit. GearyController now keeps a list of all open ComposerWindows, and
listens for YorbaApplication's 'exiting' signal. When the signal is
received, GearyController warns the user about each open ComposerWindow
with unsent text. If the user cancels the closing of any of these
ComposerWindows, GearyController cancels the edit.
This patch adds additional logging and debug statements regarding
connection drops and resets and attempts by Geary.Conversations
to reestablish a connection. There's also some small changes
to simplify the disconnect code.
Prior work on fixing #5114 included using UID ranges when a new
message came in to avoid a perceived one-off problem. This returns
to the old way of doing things (using positional addressing), which
means not having to access the database to determine what messages
to fetch.
This appears to solve the problem entirely. The Conversations
object was maintaining extra refs to Conversation objects which
had been previously removed (archived) and reporting them as gone
to the client. But, when new messages came in for that old
conversation, it mistakenly associated them and reported them as
added, which the client silently ignored (it couldn't find the
conversation in its own list).
This patch fixes two bugs causing #5271. First, the ReplayQueue
wouldn't close due to the is_closed flag being set before submitting
the internal operation that flushes the queue. Second, the
retooled fetch_email_async() wasn't checking if the folder was
opened, causing problems with the flag watcher and prefetcher.
Additionally, debug logging was improved here, which helped debug
this problem.
Prior commit failed to solve this problem. Further study leads me
to believe that the two separate replay queues (send, recv) allow
for subtle timing holes. There is now a single replay queue that
manages both types of operations, meaning each one is executing
atomically without an operation on another queue changing state
out from underneath it.
This patch changes geary-mailer to make it more usable from the
command-line (for scripting and such). Not perfect (yet), but a
start. Important additions for later is being able to specify
subject and message body.
Eric once reported a triggered assertion inside Geary.StateMachine
that was unreproducible. This change means that if it happens
again better information will be logged to try and debug and/or
reproduce it.
Previously, Geary could sometimes request elements of an email
message it already had in the database. Often this was due to
the client requesting information already present as well as one
additional field; the old implementation required all the requested
fields be pulled down.
Now Geary will work out on a message-by-message basis what is
present and what is not and request only missing fields for each
one. It will cluster messages missing the same fields into the
same request and it submits all requests simultaneously, to take
advantage of IMAP pipelining.
This work has some orthogonal benefits toward #5224, better
Dovecot support, by making the upper layers able to merge an email
using both locally-fetched data and remotely-fetched data.
Gmail supports the CHILDREN extension, which means that labels
with children are marked as such. This information can be used
to prevent unnecessary recursion when loading the folder list
(which speeds startup).
In my Yahoo! account was an email with no Date: field in the
header (spam). This triggered a lot of assertions in Geary, both
the engine and the client. This fixes them.
http://redmine.yorba.org/issues/4662, I think this looks nicer since the selection rectangle
does not visually move after an archive operation.
This is an exact revert of commit b11c1af070.
This also closes#5079, which I believe was caused by #4781 (and
could reproduce once isolated).
This commit may also close bug #5189, but need to verify further
on reporter's machine before closing.
These problems are all related to emails lacking a Message-ID in
their header, common with spam and mass-emailers.
This appears to be a timing issue between a message being deleted
and a message arriving at approx. the same time. The new event
handler dealing with incoming mail is not so strict and uses UID
addressing to be more generous in scooping up any new email than
it has in the local store.
*Believe* this to be fixed, but as this is so difficult to repro
and diagnose, there may still be some cases out there.
When an empty folder received a new message, Geary.Conversations
wasn't recognizing it.
Also, if a folder was empty in the database and received a message
when Geary wasn't monitoring it, Geary would not recognize the
new message. This corrects that as well.
Problem would occur when closing the Folder object while it was
still opening the remote folder. This patch cleans that up so
all requests waiting for it to open are properly errored and
the close can continue without waiting.
Assertion removed, replaced with big warning in debug log. Also
only fires signals once all modification has been made to
Conversations state -- potential issue here may be reentrancy.
This rather large patch makes Geary.Conversations now responsible
for reestablishing a connection with the server if it ever drops
due to error. Once reestablished, Conversations will resynchronize
and report any new messages to the client. To the client, it's
invisible.
Working on this revealed problems with session teardown and Folder
state issues, as well as a memory leak. These are all fixed in
the patch.
There remains other connection timeout problems when the network is
unavailable, but will need to be addressed in a separate patch.