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 pitrou
Recipients Ben.Darnell, christian.heimes, giampaolo.rodola, janssen, nikratio, pitrou, python-dev, r.david.murray
Date 2014-05-01.12:09:35
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1398946177.62.0.918699222848.issue20951@psf.upfronthosting.co.za>
In-reply-to
Content
Actually, the test hangs after one of the threads crashes:

test__all__ (test.test_poplib.TestPOP3_SSLClass) ... Exception in thread Thread-23:
Traceback (most recent call last):
  File "/home/antoine/cpython/default/Lib/threading.py", line 920, in _bootstrap_inner
    self.run()
  File "/home/antoine/cpython/default/Lib/test/test_poplib.py", line 218, in run
    asyncore.loop(timeout=0.1, count=1)
  File "/home/antoine/cpython/default/Lib/asyncore.py", line 212, in loop
    poll_fun(timeout, map)
  File "/home/antoine/cpython/default/Lib/asyncore.py", line 153, in poll
    read(obj)
  File "/home/antoine/cpython/default/Lib/asyncore.py", line 87, in read
    obj.handle_error()
  File "/home/antoine/cpython/default/Lib/asyncore.py", line 83, in read
    obj.handle_read_event()
  File "/home/antoine/cpython/default/Lib/asyncore.py", line 422, in handle_read_event
    self.handle_accept()
  File "/home/antoine/cpython/default/Lib/asyncore.py", line 499, in handle_accept
    self.handle_accepted(*pair)
  File "/home/antoine/cpython/default/Lib/test/test_poplib.py", line 228, in handle_accepted
    self.handler_instance = self.handler(conn)
  File "/home/antoine/cpython/default/Lib/test/test_poplib.py", line 368, in __init__
    self.push('+OK dummy pop3 server ready. <timestamp>')
  File "/home/antoine/cpython/default/Lib/test/test_poplib.py", line 82, in push
    asynchat.async_chat.push(self, data.encode("ISO-8859-1") + b'\r\n')
  File "/home/antoine/cpython/default/Lib/asynchat.py", line 190, in push
    self.initiate_send()
  File "/home/antoine/cpython/default/Lib/asynchat.py", line 243, in initiate_send
    self.handle_error()
  File "/home/antoine/cpython/default/Lib/asynchat.py", line 241, in initiate_send
    num_sent = self.send(data)
  File "/home/antoine/cpython/default/Lib/asyncore.py", line 366, in send
    result = self.socket.send(data)
  File "/home/antoine/cpython/default/Lib/ssl.py", line 667, in send
    return self._sslobj.write(data)
ssl.SSLWantReadError: The operation did not complete (read) (_ssl.c:1636)


This was due to a simplistic handling of asyncore SSL connections in test_poplib, which I've fixed by reusing the code from test_ftplib.
History
Date User Action Args
2014-05-01 12:09:37pitrousetrecipients: + pitrou, janssen, giampaolo.rodola, christian.heimes, r.david.murray, nikratio, python-dev, Ben.Darnell
2014-05-01 12:09:37pitrousetmessageid: <1398946177.62.0.918699222848.issue20951@psf.upfronthosting.co.za>
2014-05-01 12:09:37pitroulinkissue20951 messages
2014-05-01 12:09:35pitroucreate