Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
sent_mbox preference is always resetted after login #4782
Reported by mufus on 3 Mar 2015 18:23 UTC as Trac ticket #1490300
After upgrading to 1.1.0 i noticed that the "sent_mbox" preference for each user is always being resetted after each login.
My dovecot config:
Every time I log in to roundcube webmail, my
Settings > Preferences > Special Folders > Sent
is always resetted back to "Sent" (defined by Dovecot), even if I manually change it to, for example "Sent Messages" folder.
Comment by @alecpl on 3 Mar 2015 19:45 UTC
This is because server SPECIAL-USE setting has priority over Roundcube settings and because dovecot does not support SPECIAL-USE flag changes by METADATA. Or there's a bug... Please, enable imap_debug in Roundcube and provide the log. For more info see rcube_imap::set_special_folders() method.
Comment by mufus on 3 Mar 2015 20:20 UTC
Aha, if Dovecot's SPECIAL-USE value always has priority, that explains why Roundcube's value is always being reset at login time.
The reason why I noticed this in the first place:
I have always used the "Sent" folder in RC before, but with RC 1.1.0 the default Sent-folder in Roundcube was changed to "Sent Messages".
I have attached log of the imap.
Comment by @alecpl on 4 Mar 2015 07:26 UTC
I'm not sure if enabling METADATA in dovecot will fix that. I think dovecot does not support special-use flags updates yet. Anyway, this is intended behaviour and we'll not change that. If you don't like it you can set $config['imap_disabled_caps'] = array('SPECIAL-USE'); in Roundcube config.
Also, to disable Sent folder change in Roundcube settings you can add 'sent_mbox' to 'dont_override' array in the config.
Comment by jirand on 4 Jun 2015 12:57 UTC
We just stumbled across this and I have to re-open this bug.
IMHO special_use flag in IMAP is intended as advisory to the email client when it has not relevant information about what folder should be used.
If the email client already has this setting (moreover when it has been modified by the user) it should definitely have precedence before the special_use flag.
The default dovecot config is a good illustration as it says any of "Sent" and "Sent Messages" folders can be used for storing sent messages.
Comment by @alecpl on 4 Jun 2015 14:52 UTC
I do not agree with that. The problem is that dovecot's special-use flags are read-only. There wouldn't be a problem if dovecot would allow special-use flag modification. So, to have the bahaviour you want just disable SPECIAL-USE capability in Roundcube as proposed above.
Assigned to Thomas for an opinion.
Comment by mufus on 5 Jun 2015 13:44 UTC
I don't see why Roundcube should not respect the users settings like all other email clients do.
Because of this issue, lots of users now ended up having one Sent-folder in their e-mail client (Apple Mail/iOS Mail/Thunderbird/Outlook), and another one when they access webmail through Roundcube.
Comment by @alecpl on 20 Jun 2015 15:22 UTC
That's the point behind SPECIAL-USE. Clients should ignore its config if server has special folders already configured. The problem here is on the imap server which does not allow to change these assignments. Normally, client should be able to change the assignment so other clients can apply this change automatically.
Really, if there's no way to change the assignment on the server I don't see much sense in using SPECIAL-USE. In such a case it can be disabled on server or in Roundcube config.
However, the behavior could be changed the way you propose. We'd need to detect if special folders settings were ever modified/saved and if so use config instead of special-use, but I call this a workaround.
Comment by drdol on 18 Mar 2016 15:11 UTC
I run into the same issue. An customer reported this issue.
It's kind of confusing being able to define special folders in the settings but after a login the folders are reset. Would it be better to disable the possibility to change the special folder if the folder type was set by the SPECIAL-USE attribute and the server does not support a special folder attribute update.