thiell/test — Issue #118: Broken epoll.register() when stdin is a plain file
Author: thiell
Created: 2012-03-03 16:33:55+00:00
State: open
Labels: Lib/Engine

Unfortunately, when using Python 2.6, [http://docs.python.org/library/select.html?highlight=epoll#select.epoll select.epoll] doesn't work as expected. epoll.register() raises an IOError (EPERM) when trying to register sys.stdin, even in non-blocking mode.

After some investigation, it seems that epoll_ctl(2) doesn't work with regular plain file. I've opened Linux kernel ticket [http://bugzilla.kernel.org/show_bug.cgi?id=15272 #15272] about that.

As of today, clush uses a WorkerSimple bound to stdin, which is registered on Engine.EPoll engine when using Python 2.6. I'm going to change this behaviour and uses Engine.Poll by default (which is known to work well), so that clush will work with ''