[Patches] [ python-Patches-1605192 ] Make Imap Error more helpful
SourceForge.net
noreply at sourceforge.net
Tue Mar 13 19:24:59 CET 2007
Patches item #1605192, was opened at 2006-11-29 11:52
Message generated for change (Comment added) made by gbrandl
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1605192&group_id=5470
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Library (Lib)
Group: None
>Status: Closed
>Resolution: Accepted
Priority: 5
Private: No
Submitted By: Thomas Guettler (guettli)
Assigned to: Nobody/Anonymous (nobody)
Summary: Make Imap Error more helpful
Initial Comment:
Hi,
In my app I got this error:
imaplib.error: command SEARCH illegal in state AUTH.
but I did successfully login. After reading the source
of imaplib.py I realized that this was meant:
imaplib.error: command SEARCH illegal in state AUTH. Allowed after: SELECTED
Attached is a small patch to make the error message
more helpful.
----------------------------------------------------------------------
>Comment By: Georg Brandl (gbrandl)
Date: 2007-03-13 18:24
Message:
Logged In: YES
user_id=849994
Originator: NO
Thanks for the patch, applied a similar one in rev. 54343.
----------------------------------------------------------------------
Comment By: Mark Roberts (mark-roberts)
Date: 2006-12-27 17:52
Message:
Logged In: YES
user_id=1591633
Originator: NO
The patch looks great (Not as though I have a lot of say to say so..), but
it seems incongruous that you say "allowed after" when it might seem more
explicit to say "Allowed in states", like so:
"Allowed in states: %s" % (", ".join(Commands[command])
Otherwise, I'm all for more explicit error messages!
- Mark
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1605192&group_id=5470
More information about the Patches
mailing list