#5377 defect new
twisted.internet.udp.Port is disconnected by _PollLikeMixin reactors when it gets connection refused
|Reported by:||zseil||Owned by:|
Description (last modified by itamar)
SelectReactor calls selectable.doRead() even when the selectable gets disconnected, which allows udp.Port.doRead() to call protocol.connectionRefused(). In constrast, PollReactor and other call selectable.connectionLost() directly in case of bare _POLL_DISCONNECTED event. See the attached test which hangs on Poll, Epoll and Gtk2 reactors but passes on Select reactor on Linux (Ubuntu Lucid).
Possibly the test is wrong, maybe udp.Port.doRead() should stop listening if recvfrom fails with ECONNREFUSED or ECONNRESET instead of calling protocol.connectionRefused().
Change History (5)
Changed 5 years ago by zseil
comment:2 Changed 5 years ago by itamar
- Description modified (diff)
- Summary changed from _PollLikeMixin should match the bahavior of SelectReactor in case of _POLL_DISCONNECTED to twisted.internet.udp.Port is disconnected by _PollLikeMixin reactors when it gets connection refused