You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I periodically run into this AssertionError when sending mail. The culprit seems to be line 356 in getreply,
line = yield gen.Task(self.sock.read_until, '\n')
but I'm not sure about the proper fix. Posting here for discussion.
[E 141009 17:15:23 ioloop:491] Exception in callback <functools.partial object at 0x7f1460c62c00>
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/tornado/ioloop.py", line 477, in _run_callback
callback()
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 331, in wrapped
raise_exc_info(exc)
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 302, in wrapped
ret = fn(_args, *_kwargs)
File "/usr/local/lib/python2.7/dist-packages/tornado/iostream.py", line 354, in wrapper
callback(_args)
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 331, in wrapped
raise_exc_info(exc)
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 343, in _handle_exception
if tail.exit(_exc):
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 186, in exit
return self.exception_handler(type, value, traceback)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 142, in handle_exception
return runner.handle_exception(typ, value, tb)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 580, in handle_exception
self.run()
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 529, in run
yielded = self.gen.throw(_exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornadomail/message.py", line 260, in send
result = yield gen.Task(self.get_connection(fail_silently).send_messages, [self])
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 343, in _handle_exception
if tail.exit(_exc):
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 186, in exit
return self.exception_handler(type, value, traceback)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 142, in handle_exception
return runner.handle_exception(typ, value, tb)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 580, in handle_exception
self.run()
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 529, in run
yielded = self.gen.throw(_exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornadomail/backends/smtp.py", line 88, in send_messages
sent = yield gen.Task(self._send, message)
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 343, in _handle_exception
if tail.exit(_exc):
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 186, in exit
return self.exception_handler(type, value, traceback)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 142, in handle_exception
return runner.handle_exception(typ, value, tb)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 580, in handle_exception
self.run()
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 529, in run
yielded = self.gen.throw(_exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornadomail/backends/smtp.py", line 107, in _send
email_message.message().as_string())
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 343, in _handle_exception
if tail.exit(_exc):
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 186, in exit
return self.exception_handler(type, value, traceback)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 142, in handle_exception
return runner.handle_exception(typ, value, tb)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 580, in handle_exception
self.run()
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 529, in run
yielded = self.gen.throw(_exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornadomail/smtplib.py", line 748, in sendmail
yield gen.Task(self.ehlo_or_helo_if_needed)
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 343, in _handle_exception
if tail.exit(_exc):
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 186, in exit
return self.exception_handler(type, value, traceback)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 142, in handle_exception
return runner.handle_exception(typ, value, tb)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 580, in handle_exception
self.run()
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 529, in run
yielded = self.gen.throw(_exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornadomail/smtplib.py", line 552, in ehlo_or_helo_if_needed
result = yield gen.Task(self.ehlo)
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 302, in wrapped
ret = fn(_args, *_kwargs)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 574, in inner
self.set_result(key, result)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 500, in set_result
self.run()
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 529, in run
yielded = self.gen.throw(_exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornadomail/smtplib.py", line 409, in ehlo
result = yield gen.Task(self.getreply)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 557, in run
self.yield_point.start(self)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 377, in start
self.func(_self.args, *_self.kwargs)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 159, in wrapper
runner.run()
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 529, in run
yielded = self.gen.throw(_exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornadomail/smtplib.py", line 356, in getreply
line = yield gen.Task(self.sock.read_until, '\n')
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 557, in run
self.yield_point.start(self)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 377, in start
self.func(_self.args, **self.kwargs)
File "/usr/local/lib/python2.7/dist-packages/tornado/iostream.py", line 161, in read_until
self._set_read_callback(callback)
File "/usr/local/lib/python2.7/dist-packages/tornado/iostream.py", line 418, in _set_read_callback
assert not self._read_callback, "Already reading"
AssertionError: Already reading
The text was updated successfully, but these errors were encountered:
I periodically run into this AssertionError when sending mail. The culprit seems to be line 356 in getreply,
line = yield gen.Task(self.sock.read_until, '\n')
but I'm not sure about the proper fix. Posting here for discussion.
[E 141009 17:15:23 ioloop:491] Exception in callback <functools.partial object at 0x7f1460c62c00>
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/tornado/ioloop.py", line 477, in _run_callback
callback()
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 331, in wrapped
raise_exc_info(exc)
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 302, in wrapped
ret = fn(_args, *_kwargs)
File "/usr/local/lib/python2.7/dist-packages/tornado/iostream.py", line 354, in wrapper
callback(_args)
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 331, in wrapped
raise_exc_info(exc)
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 343, in _handle_exception
if tail.exit(_exc):
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 186, in exit
return self.exception_handler(type, value, traceback)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 142, in handle_exception
return runner.handle_exception(typ, value, tb)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 580, in handle_exception
self.run()
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 529, in run
yielded = self.gen.throw(_exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornadomail/message.py", line 260, in send
result = yield gen.Task(self.get_connection(fail_silently).send_messages, [self])
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 343, in _handle_exception
if tail.exit(_exc):
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 186, in exit
return self.exception_handler(type, value, traceback)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 142, in handle_exception
return runner.handle_exception(typ, value, tb)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 580, in handle_exception
self.run()
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 529, in run
yielded = self.gen.throw(_exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornadomail/backends/smtp.py", line 88, in send_messages
sent = yield gen.Task(self._send, message)
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 343, in _handle_exception
if tail.exit(_exc):
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 186, in exit
return self.exception_handler(type, value, traceback)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 142, in handle_exception
return runner.handle_exception(typ, value, tb)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 580, in handle_exception
self.run()
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 529, in run
yielded = self.gen.throw(_exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornadomail/backends/smtp.py", line 107, in _send
email_message.message().as_string())
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 343, in _handle_exception
if tail.exit(_exc):
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 186, in exit
return self.exception_handler(type, value, traceback)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 142, in handle_exception
return runner.handle_exception(typ, value, tb)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 580, in handle_exception
self.run()
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 529, in run
yielded = self.gen.throw(_exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornadomail/smtplib.py", line 748, in sendmail
yield gen.Task(self.ehlo_or_helo_if_needed)
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 343, in _handle_exception
if tail.exit(_exc):
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 186, in exit
return self.exception_handler(type, value, traceback)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 142, in handle_exception
return runner.handle_exception(typ, value, tb)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 580, in handle_exception
self.run()
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 529, in run
yielded = self.gen.throw(_exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornadomail/smtplib.py", line 552, in ehlo_or_helo_if_needed
result = yield gen.Task(self.ehlo)
File "/usr/local/lib/python2.7/dist-packages/tornado/stack_context.py", line 302, in wrapped
ret = fn(_args, *_kwargs)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 574, in inner
self.set_result(key, result)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 500, in set_result
self.run()
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 529, in run
yielded = self.gen.throw(_exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornadomail/smtplib.py", line 409, in ehlo
result = yield gen.Task(self.getreply)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 557, in run
self.yield_point.start(self)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 377, in start
self.func(_self.args, *_self.kwargs)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 159, in wrapper
runner.run()
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 529, in run
yielded = self.gen.throw(_exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornadomail/smtplib.py", line 356, in getreply
line = yield gen.Task(self.sock.read_until, '\n')
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 557, in run
self.yield_point.start(self)
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 377, in start
self.func(_self.args, **self.kwargs)
File "/usr/local/lib/python2.7/dist-packages/tornado/iostream.py", line 161, in read_until
self._set_read_callback(callback)
File "/usr/local/lib/python2.7/dist-packages/tornado/iostream.py", line 418, in _set_read_callback
assert not self._read_callback, "Already reading"
AssertionError: Already reading
The text was updated successfully, but these errors were encountered: