[issue30931] Race condition in asyncore wrongly closes channel

2017-07-14 Thread Jaume
New submission from Jaume: If a socket is closed and polled here https://github.com/python/cpython/blob/0d0a32fb91cdfea1626e6c6b77a9bc44e15a2b8a/Lib/asyncore.py#L183 the flag returned will be select.POLLNVAL (note that this can happen despite dispatcher.close() being called). This wouldn't

[issue30931] Race condition in asyncore wrongly closes channel

2017-07-14 Thread Jaume
Changes by Jaume <jaumemarhue...@gmail.com>: -- pull_requests: +2771 ___ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue30931> ___ _

[issue30931] Race condition in asyncore wrongly closes channel

2017-07-14 Thread Jaume
Changes by Jaume <jaumemarhue...@gmail.com>: -- type: -> resource usage versions: +Python 3.3, Python 3.4, Python 3.5, Python 3.6, Python 3.7 ___ Python tracker <rep...@bugs.python.org> <http://bugs.pyt

[issue30931] Race condition in asyncore wrongly closes channel

2017-07-19 Thread Jaume
Changes by Jaume <jaumemarhue...@gmail.com>: -- pull_requests: +2823 ___ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue30931> ___ _

[issue30931] Race condition in asyncore may access the wrong dispatcher

2017-07-25 Thread Jaume
Jaume added the comment: There's an alternative fix which follows a similar approach to the one you mention: https://github.com/python/cpython/pull/2707/. I personally don't like too much to reuse again again an old variable as it's true that we don't know how people are using it (although I

[issue30985] Set closing variable in asyncore at close

2017-07-21 Thread Jaume
Changes by Jaume <jaumemarhue...@gmail.com>: -- pull_requests: +2854 ___ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue30985> ___ _

[issue30985] Set closing variable in asyncore at close

2017-07-21 Thread Jaume
Changes by Jaume <jaumemarhue...@gmail.com>: -- nosy: walkhour priority: normal severity: normal status: open title: Set closing variable in asyncore at close ___ Python tracker <rep...@bugs.python.org> <http://bugs.python