[Twisted-Python] epollreactor for pyicq-0.6-t

glyph at divmod.com glyph at divmod.com
Tue Jan 8 09:59:06 EST 2008

On 02:50 pm, steven_zhou at ctl.creative.com wrote:
>The thing I do may sounds a bit wierd. I am using a pyicq-0.6-t. As
>pyicq-0.6-t only works with twisted-2.2 or earlier, so I chose to 
>twisted-2.2. However, I wished to use epollreactor as the default
>selectreactor only supports 1024 file descriptors. So I copied the 
>files of epollreactor which is installed on twisted-2.5 to the
>site-packages/twisted-2.2 directory. I copied 5 files in the total,
>epollreactor.py, epoll..pyx to the twisted/internet directory, 
>_epoll.pyc and _epoll.so to twisted/python directory. I can't remember 
>exact file names. I copied it with a hope that it works. I am not sure
>whether I am doing thing stupid here. correct me if I am.

"stupid" might be a harsh word, but what you're doing shouldn't be 
expected to work.  I'm surprised that it has worked as well as you 
suggest that it has.
>The thing is, after I changed the reactor.py to import epollreactor,
>pyicq-0.6-t seems to be using epollreactor but it still can only 
>1024 open sockets. I thought the problem is only in selectreactor?

You might want to check your ulimits.  However, twisted 2.2 might have 
been calling select() in any number of places.  And Python 2.4.3 had a 
bug in it which would have caused a problem regardless.  And there might 
be a bug in the interaction of random bits of code from twisted 2.5 and 
2.2.  Whatever the problem is, you're on your own trying to sort it out 
until you can upgrade to a supported version :)
>The information in this message is confidential and may be legally
>privileged.  It is intended solely for the addressee.  Access to this
>message by anyone else is unauthorized.

Please do not attach notices like this to messages on this mailing list, 
given that the "addressee" in this case is the entire internet :).

More information about the Twisted-Python mailing list