After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 741186 - Re-attempt moving "Sent but not saved" messages to Sent at startup/periodically
Re-attempt moving "Sent but not saved" messages to Sent at startup/periodically
Status: RESOLVED DUPLICATE of bug 727679
Product: geary
Classification: Other
Component: engine
master
Other Linux
: Normal normal
: ---
Assigned To: Geary Maintainers
Geary Maintainers
Depends on:
Blocks:
 
 
Reported: 2014-12-06 01:45 UTC by Michael Gratton
Modified: 2016-05-16 11:12 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
When filling postmaster queue, include all messages, not just unsent. (1.04 KB, patch)
2014-12-06 04:59 UTC, Michael Gratton
none Details | Review
Don't ignore sent messages in postman queue, try to save them. (11.72 KB, patch)
2014-12-06 04:59 UTC, Michael Gratton
none Details | Review
Prefill postman queue only after account has been opened. (2.61 KB, patch)
2014-12-06 04:59 UTC, Michael Gratton
none Details | Review

Description Michael Gratton 2014-12-06 01:45:04 UTC
Over time I am collecting more and more messages in my outbox marked as "This message was sent successfully, but could not be saved to Sent Mail". Geary does not appear to attempt to re-save them to my Sent mailbox after that initial attempt.

Regardless of why the message could not be saved in the first place, Geary should re-attempt to save them rather than just leaving them there. Some opportune times to do this would include app startup, when sending another message, or maybe periodically.

This is related to #727679 (although that seems to have been co-opted by a side issue) and more tangentially to #733541.
Comment 1 Michael Gratton 2014-12-06 04:59:45 UTC
Created attachment 292225 [details] [review]
When filling postmaster queue, include all messages, not just unsent.

Bug #741186.

* src/engine/imap-db/outbox/smtp-outbox-folder.vala: Remove where clause
  from prefill query.
Comment 2 Michael Gratton 2014-12-06 04:59:50 UTC
Created attachment 292226 [details] [review]
Don't ignore sent messages in postman queue, try to save them.

Bug #741186

* src/engine/imap-db/outbox/smtp-outbox-folder.vala
  (Geary.SmtpOutboxFolder.do_postman_async): Flag sent messages rather
  than skipping them, only try sending messages that are unsent, always
  try saving all messages, re-queue if unsent or unsaved.
Comment 3 Michael Gratton 2014-12-06 04:59:55 UTC
Created attachment 292227 [details] [review]
Prefill postman queue only after account has been opened.

Bug #741186

* src/engine/imap-db/outbox/smtp-outbox-folder.vala
  (Geary.SmtpOutboxFolder.SmtpOutboxFolder): Prefil on account start.
  (Geary.SmtpOutboxFolder.do_postman_async): Split queue prefil code into
  new fill_outbox_queue method.
Comment 4 Michael Gratton 2014-12-06 05:27:18 UTC
Hmm, I wasn't expecting that to attach as three separate patches. Anywho, this is a rough implementation that:

 1. Fills the postman queue on account start, rather than postman startup
 2. Includes all outbox messages when filling it
 3. Postman processes both sent and unsent messages, and only removes messages from the queue if sent and saved (assuming if the account is not configured/able to save sent messages)

With these patches, Geary will start trying to save sent messages on startup, and continue attempting to save them when saving fails after a successful send. It is a it rough around the edges for me in that when first starting Geary with sent messages in the outbox, postman spews errors until Geary picks up the fact that my mailbox delim is '.', not '/', but I don't know how to get notified of that.
Comment 5 Michael Gratton 2016-05-16 11:12:27 UTC
These patches are a bit sketchy - they only work on Geary restart and occasionally keep on copying the message over and over, leading to many duplicates.

In any case, this is basically a dupe of #727679

*** This bug has been marked as a duplicate of bug 727679 ***