Univention Bugzilla – Bug 56648
40_mail.43_dovecot_shared_folder_create_subfolder_with_acls.py test fails
Last modified: 2024-03-08 11:10:55 CET
402023-08-31 20:34:47.66743141 Traceback (most recent call last): 402023-08-31 20:34:47.66744641 File "/usr/share/ucs-test/40_mail/43_dovecot_shared_folder_create_subfolder_with_acls.py", line 140, in <module> 402023-08-31 20:34:47.67137641 main() 402023-08-31 20:34:47.67141741 File "/usr/share/ucs-test/40_mail/43_dovecot_shared_folder_create_subfolder_with_acls.py", line 81, in main 402023-08-31 20:34:47.67142841 imap1.copy('1', 'INBOX', folder_name) 402023-08-31 20:34:47.67143941 File "/usr/share/ucs-test/40_mail/essential/mail.py", line 170, in copy 402023-08-31 20:34:47.67144941 rv, data = self.connection.copy(message_set, new_mailbox) 402023-08-31 20:34:47.67147041 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 402023-08-31 20:34:47.67148041 File "/usr/lib/python3.11/imaplib.py", line 486, in copy 402023-08-31 20:34:47.67149541 return self._simple_command('COPY', message_set, new_mailbox) 402023-08-31 20:34:47.67150541 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 402023-08-31 20:34:47.67151641 File "/usr/lib/python3.11/imaplib.py", line 1230, in _simple_command 402023-08-31 20:34:47.67152541 return self._command_complete(name, self._command(name, *args)) 402023-08-31 20:34:47.67153541 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 402023-08-31 20:34:47.67154541 File "/usr/lib/python3.11/imaplib.py", line 1055, in _command_complete 402023-08-31 20:34:47.67155441 raise self.error('%s command error: %s %s' % (name, typ, data)) 402023-08-31 20:34:47.67156641 imaplib.IMAP4.error: COPY command error: BAD [b'Error in IMAP command COPY: Invalid messageset (0.001 + 0.000 secs).'] https://git.knut.univention.de/univention/ucs/-/issues/1738
We have a workaround in the tests currently. The description of 3 failing tests is: commit 7a83c0617f0096552f734c30476486b64f0c33a5 Author: Soenke Schwardt-Krummrich <schwardt@univention.de> Date: Sun Apr 30 17:09:36 2023 +0200 DRPOME: Flush postfix queue and dovecot auth cache For some currently unknown reason, the dovecot's auth cache contains wrong information. The test mails are correctly delivered to /var/spool/dovecot/private///Maildir/.... via SMTP and LMTP into the IMAP mailbox. But when ucs-test is accessing the mailbox via IMAP, the user information seem to be invalid/unknown/not yet correct, so dovecot is looking for the requested mailbox in /var/spool/dovecot/private//... which is obviously incorrect. This commit fixes the failure of the test but not the actual problem in/with dovecot. Bug #56648 test/ucs-test/tests/40_mail/42_dovecot_rename_mail_primary_address.py | 8 +++++--- test/ucs-test/tests/40_mail/42_dovecot_rename_user.py | 6 ++++++ test/ucs-test/tests/40_mail/43_dovecot_shared_folder_create_subfolder_with_acls.py | 6 ++++++ So I set this bug to REOPENED so that we fix the real issue in dovecot.
The latest analysis was, that there was a change in UCS 5.2 that it takes ~5 minutes so that the cache is invalidated. That sounds too long. If we cannot fix this by config and restore the UCS 5.0 behavior, we could create a listener module which calls "doveadm auth cache flush" when a user changed his password or a user was removed.
ucs-test (12.0.9) 9531f36a279d | DROPME: disable dovecot auth cache in tests