Ticket #183 (closed Bugs: fixed)
IMAP subfolders not displayed on Dovecot servers
| Reported by: | octo | Owned by: | octo |
|---|---|---|---|
| Priority: | normal | Milestone: | 2.0 |
| Component: | LogicMail | Version: | |
| Keywords: | Cc: | ||
| Blocked By: | Blocking: |
Description
This problem only occurs when the folder listing is retrieved using the "LSUB" command (show only subscribed), which is the default behavior.
In its CAPABILITY string, Dovecot advertises its support for the CHILDREN attributes on IMAP folders. When using the LIST command, these attributes are returned to the client. But when using the LSUB command, no attributes are returned. This causes LogicMail's workarounds to not kick in, and the child folders are never seen.
LogicMail's normal behavior for LSUB produces the following output on a test Dovecot setup:
A02 LSUB "" "%" * LSUB () "." "Trash" * LSUB () "." "Sent" * LSUB () "." "Drafts" * LSUB () "." "Templates" * LSUB () "." "Junk" * LSUB () "." "INBOX" * LSUB () "." "folder1"
However, Thunderbird uses a different parameter, producing output like this:
A03 LSUB "" "*" * LSUB () "." "Trash" * LSUB () "." "Sent" * LSUB () "." "Drafts" * LSUB () "." "Templates" * LSUB () "." "Junk" * LSUB () "." "INBOX" * LSUB () "." "folder1" * LSUB () "." "folder1.folder1a" * LSUB () "." "folder1.folder1b"
For the LIST command, the same results (plus folder attributes) are observed. Research will need to be done to determine the correct way of retrieving a folder list, and to determine if LogicMail needs to change its approach.
Change History
comment:2 Changed 21 months ago by octo
- Status changed from accepted to closed
- Resolution set to fixed
Fixed by changeset [646].
The fix for this modified the way "Show only subscribed" works. Initially, it was just a drop-in of LSUB in place of LIST. Now it works like this:
- LSUB "" "*" (gets a dump of all subscribed folders)
- LIST recursively, using the same old logic as before
- Prune the results, based on the set of subscribed folders, in the following way:
- INBOX is always included and selectable
- Folders that are not subscribed, and have no children, are now omitted
- Folders that are not subscribed, but do have children, are still included
Hopefully this will all work as intended, and doesn't introduce any other bugs or undesired behavior. If it does, feel free to re-open this ticket or open new ones as appropriate.
