Message152612
imaplib does not qupote mailbox names when it's sending it's query to the server in response to a status request, for example. This will lead to very strange errors if mailboxes are accessed which contain spaces:
i.e.
connection.status("mailbox name", "(MESSAGES)")
will return
File "/home/joe/test/imaplib.py", line 920, in _command_complete
raise self.error('%s command error: %s %s' % (name, typ, data))
imaplib.error: STATUS command error: BAD [b'Error in IMAP command STATUS: Status items must be list.']
which indicates that the error is within the actual flag list. It is not, however:
connection.status("\"mailbox name\"", "(MESSAGES)")
works as expected. This may arguably be or not be a bug -- however it is REALLY confusing to the user. Maybe at least a note should be included somewhere that -- just to be safe -- mailbox names should be quoted.
All the best,
Joe |
|
Date |
User |
Action |
Args |
2012-02-04 12:04:58 | joebauer | set | recipients:
+ joebauer |
2012-02-04 12:04:58 | joebauer | set | messageid: <1328357098.01.0.78801274991.issue13940@psf.upfronthosting.co.za> |
2012-02-04 12:04:57 | joebauer | link | issue13940 messages |
2012-02-04 12:04:56 | joebauer | create | |
|