Issue #23485: Enhance and update selectors doc and test_selectors

Selector.select() is now retried with the recomputed timeout when interrupted
by a signal.

Write an unit test with a signal handler raising an exception, and a unit with
a signal handler which does not raise an exception (it does nothing).
This commit is contained in:
Victor Stinner 2015-03-31 12:08:09 +02:00
parent 45ca48b03d
commit b310173319
2 changed files with 40 additions and 3 deletions

View file

@ -159,6 +159,12 @@ below:
timeout has elapsed if the current process receives a signal: in this
case, an empty list will be returned.
.. versionchanged:: 3.5
The selector is now retried with a recomputed timeout when interrupted
by a signal if the signal handler did not raise an exception (see
:pep:`475` for the rationale), instead of returning an empty list
of events before the timeout.
.. method:: close()
Close the selector.