[18.0][FIX] mail_cleanup: command CLOSE illegal in state AUTH, only allowed i…#3436
Open
[18.0][FIX] mail_cleanup: command CLOSE illegal in state AUTH, only allowed i…#3436
Conversation
cyrilmanuel
approved these changes
Nov 4, 2025
sebalix
reviewed
Dec 5, 2025
| if server.server_type == "imap": | ||
| try: | ||
| imap_server = server.connect() | ||
| imap_server.select() |
Contributor
There was a problem hiding this comment.
No need to remove this instruction from _cleanup_fetchmail_server and _purge_fetchmail_server? No side-effect to keep them?
Contributor
Author
There was a problem hiding this comment.
Hello, no side effect to keep them. But I will remove them to be more consistent.
…n states SELECTED
3e7bfa9 to
d5418ef
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
…n states SELECTED
Fixing: #3435
You need to have a
server.select(). These selects are done into the methods_cleanup_fetchmail_serverand_purge_fetchmail_serverif you don't match any of the IF statements. You will never do theserver.select()and thus endup with a stacktrace.https://github.com/OCA/server-tools/blob/18.0/mail_cleanup/models/fetchmail_server.py#L125
https://github.com/OCA/server-tools/blob/18.0/mail_cleanup/models/fetchmail_server.py#L128C30-L128C53