bpo-32568: make select.epoll() and its docs consistent by taleinat · Pull Request #7840 · python/cpython
* 'flags' is indeed deprecated, but there was a validation on its value, contrary to the docs saying it is "completely ignored". This removes that check. * 'sizehint' is still used when 'epoll_create1()' is unavailable, so this adds mention of this in the docs. * Make 'sizehint' accept -1 again, which is replaced with FD_SETSIZE-1. This is needed to have a default value available at the Python level allowing to set this, since FD_SETSIZE is not exposed to Python. (see: bpo-31938)
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request
Jun 30, 2018* `flags` is indeed deprecated, but there is a validation on its value for backwards compatibility reasons. This adds mention of this in the docs. * The docs say that `sizehint` is deprecated and ignored, but it is still used when `epoll_create1()` is unavailable. This adds mention of this in the docs. * `sizehint=-1` is acceptable again, and is replaced with `FD_SETSIZE-1`. This is needed to have a default value available at the Python level, since `FD_SETSIZE` is not exposed to Python. (see: bpo-31938) * Reject `sizehint=0` since it is invalid to pass on to `epoll_create()`. The relevant tests have also been updated. (cherry picked from commit 0cdf5f4) Co-authored-by: Tal Einat <taleinat+github@gmail.com>
taleinat added a commit to taleinat/cpython that referenced this pull request
Jun 30, 2018…H-7840) * `flags` is indeed deprecated, but there is a validation on its value for backwards compatibility reasons. This adds mention of this in the docs. * The docs say that `sizehint` is deprecated and ignored, but it is still used when `epoll_create1()` is unavailable. This adds mention of this in the docs. * `sizehint=-1` is acceptable again, and is replaced with `FD_SETSIZE-1`. This is needed to have a default value available at the Python level, since `FD_SETSIZE` is not exposed to Python. (see: bpo-31938) * Reject `sizehint=0` since it is invalid to pass on to `epoll_create()`. The relevant tests have also been updated.. (cherry picked from commit 0cdf5f4) Co-authored-by: Tal Einat <taleinat+github@gmail.com>
taleinat added a commit that referenced this pull request
Jun 30, 2018…8024) * `flags` is indeed deprecated, but there is a validation on its value for backwards compatibility reasons. This adds mention of this in the docs. * The docs say that `sizehint` is deprecated and ignored, but it is still used when `epoll_create1()` is unavailable. This adds mention of this in the docs. * `sizehint=-1` is acceptable again, and is replaced with `FD_SETSIZE-1`. This is needed to have a default value available at the Python level, since `FD_SETSIZE` is not exposed to Python. (see: bpo-31938) * Reject `sizehint=0` since it is invalid to pass on to `epoll_create()`. The relevant tests have also been updated. (cherry picked from commit 0cdf5f4) Co-authored-by: Tal Einat <taleinat+github@gmail.com>
taleinat added a commit that referenced this pull request
Jun 30, 2018GH-8025) * `flags` is indeed deprecated, but there is a validation on its value for backwards compatibility reasons. This adds mention of this in the docs. * The docs say that `sizehint` is deprecated and ignored, but it is still used when `epoll_create1()` is unavailable. This adds mention of this in the docs. * `sizehint=-1` is acceptable again, and is replaced with `FD_SETSIZE-1`. This is needed to have a default value available at the Python level, since `FD_SETSIZE` is not exposed to Python. (see: bpo-31938) * Reject `sizehint=0` since it is invalid to pass on to `epoll_create()`. The relevant tests have also been updated. (cherry picked from commit 0cdf5f4)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters