Giampaolo Rodola' <g.rod...@gmail.com> added the comment:

I'm not sure I understand what EPOLLEXCLUSIVE is about. Could you provide a use 
case?

Also, there are other constants which may also be useful such as EPOLLWAKEUP 
and EPOLLONESHOT:
http://man7.org/linux/man-pages/man2/epoll_ctl.2.html
So perhaps it makes more sense to expose a lower-level "extra_events" argument 
instead, which is more flexible and also saves us from the hassle of describing 
what the new argument is about (which really is a Linux kernel thing) in the 
doc:

>>> s.register(fd, EVENT_READ, extra_events=select.EPOLLEXCLUSIVE | 
>>> select.EPOLLONESHOT)

That raises the question whether we should also have an "extra_events" argument 
for modify() method (probably yes). 

But again, I think it makes sense to understand what's the use case of these 
constants first, because if they are rarely used maybe who needs them can 
simply look at the source and use s._selector.modify() directly.

----------
nosy: +neologix, yselivanov

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

Reply via email to