R. David Murray <rdmur...@bitdance.com> added the comment:

Heh, of course the socket server also only ends with ctl-C.  And I misread the 
CAN example, it won't spin because the read isn't wrapped in a try/except.  So 
yes, that should use a with on the socket as well, since the with will close 
the socket on a ctl-C, unlike a close statement after the loop which will never 
be reached.

----------

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

Reply via email to