thunderbird / thunderbird/thunderbird-android

UX: Display message if folder contains only old messages, which will not by synchronized

Open
#3,055 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

type: enhancement
Dominant language
Kotlin
Stars
14k
Forks
2.8k
Avg merge
3d 3h
Merged PRs (30d)
57

Description

When manually synchronizing a folder containing only old messages (= older than the sync-time configured), a small note about this should be shown. This could read like (basic version, easy to implement):

  • No current messages found.
  • The folder contains only old messages, which will not by synchronized.

As a plus, the message could be more elaborated, like this:

  • The folder contains 12 old messages, but no current ones.
  • The folder contains more than 100 messages, none of which is newer than YYYY-MM-DD.
Actual behavior

Currently, when manually synchronizing a folder containing only old messages, the syncing-progress elements are show, and vanish, then only the empty folder is shown. The user has no clue whether something went wrong, which is very confusing. In fact, users often think something went wrong, and ask their acquaintances for support.

Steps to reproduce
  1. Find a folder containing some messages, but all of them are older then the sync-time configured in K9mail for this account.
  2. Open this folder in k9mail
  3. Press the "sync" button (or slide down to start syncing):
    • The information "loading messages …" will be shown for a few seconds.
    • You will be left with an empty folder.

Below please find a log of the relevant action showing that the relevant information is already there.

Environment

K-9 Mail version:5.402
Account type: IMAP

Logtrace

This logtrace show the relevant action. Ad can been seen, the folder "ExampleFolder" contains 14 messages, and the search "SINCE 01-Dec-2017" yields zero messaged (which is okay).

MessagingController: Running command 'getFolderUnread:john.doe@example-com:ExampleFolder', seq = 37 (foreground priority)
MessagingController:  Command 'getFolderUnread:john.doe@example-com:ExampleFolder' completed
MessagingController: Running command 'synchronizeMailbox', seq = 38 (background priority)
MessagingController: Synchronizing folder john.doe@example-com:ExampleFolder
MessagingController: SYNC: About to process pending commands for account john.doe@example-com
MessagingController: SYNC: About to get local folder ExampleFolder
LocalFolder: Updated last UID for folder ExampleFolder to 0
MessagingController: SYNC: About to get remote folder ExampleFolder
MessagingController: SYNC: About to open remote folder ExampleFolder
ImapConnection: conn166444983>>> 22 NOOP
ImapResponseParser: conn166444983<<<#22# [OK, NOOP completed]
ImapConnection: conn166444983>>> 23 EXAMINE "INBOX.ExampleFolder"
ImapResponseParser: conn166444983<<<#null# [FLAGS, [NonJunk, $Forwarded, \Draft, \Answered, \Flagged, \Deleted, \Seen, \Recent]]
ImapResponseParser: conn166444983<<<#null# [OK, [PERMANENTFLAGS, []], No permanent flags permitted]
ImapResponseParser: conn166444983<<<#null# [14, EXISTS]
ImapResponseParser: conn166444983<<<#null# [0, RECENT]
ImapResponseParser: conn166444983<<<#null# [OK, [UIDVALIDITY, 1365576686], Ok]
ImapResponseParser: conn166444983<<<#null# [OK, [MYRIGHTS, acdilrsw], ACL]
ImapResponseParser: conn166444983<<<#23# [OK, [READ-ONLY], Ok]
ImapFolder: Got untagged EXISTS with value 14 for john.doe@example-com:ExampleFolder/MessagingController/conn166444983
MessagingController: SYNC: Remote message count for folder ExampleFolder is 14
MessagingController: SYNC: About to get messages 1 through 14 for folder ExampleFolder
ImapConnection: conn166444983>>> 24 UID SEARCH 1:14 SINCE 01-Dec-2017 NOT DELETED
ImapResponseParser: conn166444983<<<#null# [SEARCH]
ImapResponseParser: conn166444983<<<#24# [OK, SEARCH done.]
MessagingController: SYNC: Got 0 messages for folder ExampleFolder
MessagingController: Only syncing messages after Wed Dec 06 00:00:00 GMT+01:00 2017
MessagingController: SYNC: Have 0 unsynced messages
MessagingController: SYNC: Have 0 large messages and 0 small messages out of 0 unsynced messages
MessagingController: SYNC: Fetching 0 small messages for folder ExampleFolder
MessagingController: SYNC: Done fetching small messages for folder ExampleFolder
MessagingController: SYNC: Fetching large messages for folder ExampleFolder
MessagingController: SYNC: Done fetching large messages for folder ExampleFolder
MessagingController: SYNC: About to sync flags for 0 remote messages for folder ExampleFolder
MessagingController: SYNC: Synced remote messages for folder ExampleFolder, 0 new messages
MessagingController: Done synchronizing folder john.doe@example-com:ExampleFolder @ …date… with 0 new messages
MessagingController: Done synchronizing folder john.doe@example-com:ExampleFolder
MessagingController:  Command 'synchronizeMailbox' completed
MessagingController: Running command 'sendPendingMessages', seq = 39 (background priority)
MessagingController:  Command 'sendPendingMessages' completed

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the MessagingController synchronizeMailbox flow shown in the log, especially the point where it reports 0 new messages after the date-filtered search. Trace how the folder view receives the synchronization result. Done means a manually synchronized folder with no current messages shows an explanatory note instead of appearing simply empty.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, kotlin
Domain
mobile
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.