Another Socket in Python

Erik Max Francis max at
Sat Aug 17 20:01:36 CEST 2002

Steven wrote:

> IIRC one thing to remember with select is that  you don't pass the
> actual
> socket in a list, you pass the file descriptor/number. You can get
> this by
> using the socket objects fileno() method.

That's not true in Python's implementation of select; the lists passed
in can be integers (representing file descriptors) or socket objects
(actually, any objects supporting a .fileno method).

 Erik Max Francis / max at /
 __ San Jose, CA, US / 37 20 N 121 53 W / ICQ16063900 / &tSftDotIotE
/  \ There is nothing so subject to the inconstancy of fortune as war.
\__/ Miguel de Cervantes
    Church /
 A lambda calculus explorer in Python.

More information about the Python-list mailing list