This issue tracker has been migrated to GitHub ,
and is currently read-only.
For more information,
see the GitHub FAQs in the Python's Developer Guide.
Created on 2012年02月04日 12:04 by joebauer, last changed 2022年04月11日 14:57 by admin.
| Files | ||||
|---|---|---|---|---|
| File name | Uploaded | Description | Edit | |
| issue13940.patch | maciej.szulik, 2015年11月13日 23:11 | review | ||
| Pull Requests | |||
|---|---|---|---|
| URL | Status | Linked | Edit |
| PR 6395 | open | bearbin, 2018年04月06日 09:38 | |
| Messages (8) | |||
|---|---|---|---|
| msg152612 - (view) | Author: Johannes Bauer (joebauer) | Date: 2012年02月04日 12:04 | |
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
|
|||
| msg222160 - (view) | Author: Mark Lawrence (BreamoreBoy) * | Date: 2014年07月03日 08:38 | |
@Joe sorry for the delay in getting back to you. @David is this within your remit? |
|||
| msg222175 - (view) | Author: R. David Murray (r.david.murray) * (Python committer) | Date: 2014年07月03日 13:14 | |
Yes. It will be necessary to check the RFC to figure out what should be done here. |
|||
| msg241131 - (view) | Author: Maciej Szulik (maciej.szulik) * (Python triager) | Date: 2015年04月15日 16:48 | |
Joe is correct, according to the spec the names containing special chars (atom-specials) require names to be quoted (https://tools.ietf.org/html/rfc3501#section-5.1): 1) Any character which is one of the atom-specials (see the Formal Syntax) will require that the mailbox name be represented as a quoted string or literal. I'll be working on a patch for that. |
|||
| msg254418 - (view) | Author: Maciej Szulik (maciej.szulik) * (Python triager) | Date: 2015年11月09日 22:35 | |
Currently working on a patch for this. |
|||
| msg254634 - (view) | Author: Maciej Szulik (maciej.szulik) * (Python triager) | Date: 2015年11月13日 23:11 | |
From imaplib.IMAP4 class description we're stating to quote parameters if necessary. This patch adds that capability according to https://tools.ietf.org/html/rfc3501#section-5.1 |
|||
| msg256127 - (view) | Author: Maciej Szulik (maciej.szulik) * (Python triager) | Date: 2015年12月08日 20:37 | |
siemer thx for the comments in the review. I'll try to address them by the end of this week. |
|||
| msg315084 - (view) | Author: Alexander Harkness (bearbin) * | Date: 2018年04月08日 13:19 | |
Pull Request opened on GH to fix this issue: https://github.com/python/cpython/pull/6395 |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:57:26 | admin | set | github: 58148 |
| 2018年04月21日 08:57:32 | mcepl | set | nosy:
+ mcepl |
| 2018年04月08日 13:19:13 | bearbin | set | messages:
+ msg315084 versions: + Python 3.6, Python 3.7, Python 3.8 |
| 2018年04月06日 22:36:41 | BreamoreBoy | set | nosy:
- BreamoreBoy |
| 2018年04月06日 09:44:22 | bearbin | set | nosy:
+ bearbin |
| 2018年04月06日 09:38:48 | bearbin | set | stage: patch review pull_requests: + pull_request6103 |
| 2015年12月08日 20:37:45 | maciej.szulik | set | messages: + msg256127 |
| 2015年11月13日 23:11:53 | maciej.szulik | set | files:
+ issue13940.patch keywords: + patch messages: + msg254634 |
| 2015年11月09日 22:35:30 | maciej.szulik | set | messages: + msg254418 |
| 2015年04月15日 16:48:14 | maciej.szulik | set | nosy:
+ maciej.szulik messages: + msg241131 |
| 2014年07月03日 13:14:45 | r.david.murray | set | nosy:
+ barry messages: + msg222175 components: + email |
| 2014年07月03日 08:38:29 | BreamoreBoy | set | nosy:
+ r.david.murray, BreamoreBoy messages: + msg222160 versions: + Python 3.4, Python 3.5, - Python 3.1 |
| 2012年02月04日 12:04:57 | joebauer | create | |