Message304473
Although it's documented as -1 in Linux man page [1], from my quick tests I was not able to get any error with negative values different from -1 and it seems to wait indefinitely as expected. Looking also at its implementation in [2], it doesn't seem to differentiate between negative values. It could be argued that is implementation dependent at the moment and the behaviour might change in the future.
But, on a related note, the Python documentation doesn't say much either as what are acceptable values for the timeout parameter, see [3].
So at the moment there isn't any discrepancy between the Python documentation and the current behaviour IMHO, but I'm happy to open a separate task and send a PR if you think this should be improved/fixed too.
[1] http://man7.org/linux/man-pages/man2/epoll_wait.2.html
[2] http://elixir.free-electrons.com/linux/latest/source/fs/eventpoll.c#L1754
[3] https://docs.python.org/3.7/library/select.html |
|
Date |
User |
Action |
Args |
2017-10-16 13:19:50 | Riccardo Coccioli | set | recipients:
+ Riccardo Coccioli, ronaldoussoren, vstinner, ned.deily, serhiy.storchaka, koobs |
2017-10-16 13:19:50 | Riccardo Coccioli | set | messageid: <1508159990.36.0.213398074469.issue31334@psf.upfronthosting.co.za> |
2017-10-16 13:19:50 | Riccardo Coccioli | link | issue31334 messages |
2017-10-16 13:19:50 | Riccardo Coccioli | create | |
|