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.

Author rtmq
Recipients rtmq
Date 2007-09-27.05:49:33
SpamBayes Score 0.03524509
Marked as misclassified No
Message-id <1190872174.76.0.553436258502.issue1210@psf.upfronthosting.co.za>
In-reply-to
Content
imaplib does not run under Python 3.

The following two-line python program, named testimap.py,
works when run from a Windows XP system shell prompt
using Python 2.5.1, but fails with Python 3.0.  It
appears that the logic does not follow the distinction
between characters and bytes in Python 3.


import imaplib
mail=imaplib.IMAP4("mail.rtmq.infosathse.com")


e:\python25\python   testimap.py
e:\python30\python   testimap.py 2>f:syserr


The last line produced the trace:


Traceback (most recent call last):
  File "testimap.py", line 10, in <module>
    mail=imaplib.IMAP4("mail.rtmq.infosathse.com")
  File "e:\python30\lib\imaplib.py", line 184, in __init__
    self.welcome = self._get_response()
  File "e:\python30\lib\imaplib.py", line 962, in _get_response
    self._append_untagged(typ, dat)
  File "e:\python30\lib\imaplib.py", line 800, in _append_untagged
    if typ in ur:
TypeError: unhashable type: 'bytes'
History
Date User Action Args
2007-09-27 05:49:35rtmqsetspambayes_score: 0.0352451 -> 0.03524509
recipients: + rtmq
2007-09-27 05:49:34rtmqsetspambayes_score: 0.0352451 -> 0.0352451
messageid: <1190872174.76.0.553436258502.issue1210@psf.upfronthosting.co.za>
2007-09-27 05:49:34rtmqlinkissue1210 messages
2007-09-27 05:49:33rtmqcreate