select.register not found

Andrew Bennetts andrew-pythonlist at puzzling.org
Sat May 3 02:34:24 EDT 2003


On Sat, May 03, 2003 at 06:20:55AM +0000, Neil Hodge wrote:
> All:
> 
> >>> dir(select)
> ['POLLERR', 'POLLHUP', 'POLLIN', 'POLLMSG', 'POLLNVAL',
> 'POLLOUT', 'POLLPRI', 'POLLRDBAND', 'POLLRDNORM',
> 'POLLWRBAND', 'POLLWRNORM', '__doc__', '__file__',
> '__name__', 'error', 'poll', 'select']
> 
> i.e., no "register", even though the docs say it should be there:
> 
> http://www.python.org/doc/current/lib/poll-objects.html
> 
> Anyone know why its not there?  Thanks.

Because the docs say it's a method of a polling object, as returned by
select.poll.  e.g.
    
    >>> import select
    >>> dir(select.poll())
    ['poll', 'register', 'unregister']

-Andrew.






More information about the Python-list mailing list