Ticket #3793 defect closed duplicate
imap4 doesn't cope when FLAGS are returned with RFC822.TEXT
| Reported by: | jc44 | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Keywords: | ||
| Cc: | Branch: | ||
| Author: | Launchpad Bug: |
Description (last modified by exarkun) (diff)
When doing a IMAP4Client.fetchBody some mail servers will return FLAGS as well as RFC822.TEXT because the /Seen flag has become set (RFC3501 says this SHOULD happen). If this occurs then the reply is thrown away by Command.finish in the lines:
elif N >= 3 and names[1] in self._2_RESPONSES:
if isinstance(names[2], list) and len(names[2]) >= 1 and names[2][0] == 'FLAGS' and 'FLAGS' not in self.args:
unuse.append(L)
else:
send.append(L)
I can find no way of getting the flags as well as the body in order to get 'FLAGS' in self.args. This means that no unseen message can be retrieved from this server.
I'm not sure I understand why a line with FLAGS in it wants to be discarded - at most I would expect the FLAGS element to be removed rather that the whole thing (and in my case it would be useful if the FLAGS were returned)
Change History
Note: See
TracTickets for help on using
tickets.
