Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.
Table 16.3 lists some of the other Python modules which are related to network and socket programming. The select module is usually used in conjunction with the socket module when developing lower-level socket applications. It provides the select() function which manages sets of socket objects. One of the most useful things it does is to take a set of sockets and listen for active connections on them. The select() function will block until at least one socket is ready for communication, and when that happens, it provides you with a set of which ones are ready for reading. (It can also determine which are ready for writing, although that is not as common as the former operation.)
| Module | Description |
|---|---|
| asyncore | provides infrastructure to create networked applications which process clients asynchronously |
| select | manages multiple socket connections in a single-threaded network server application |
| SocketServer | high-level module which provides server classes for networked applications, complete with forking or threading varieties |