Mark Dickinson <dicki...@gmail.com> added the comment:

Getting rid of the and ... on the handle_read_event didn't make a 
difference:  I still get the hang in test_close_when_done.

But if I get rid of the and clause on the handle_write_event branch then
all the test_asynchat tests pass.  So that block now looks like:

        if flags & select.POLLIN and (obj.connected or obj.accepting):
            obj.handle_read_event()
        if flags & select.POLLOUT:
            obj.handle_write_event()
        if flags & select.POLLPRI and obj.connected:
            obj.handle_expt_event()
        if flags & (select.POLLHUP | select.POLLERR | select.POLLNVAL):
            obj.handle_close()

in my code.  So we're making progress (maybe). Unfortunately, 
test_asyncore now fails with:

======================================================================
FAIL: test_readwrite (__main__.HelperFunctionTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "Lib/test/test_asyncore.py", line 161, in test_readwrite
    self.assertEqual(getattr(tobj, attr), attr==expectedattr)
AssertionError: False != True

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue5798>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to