[Python-Dev] asyncore fixes in Python 2.6 broke Zope's version of medusa

Daniel Stutzbach daniel at stutzbachenterprises.com
Thu Mar 5 20:43:52 CET 2009


On Thu, Mar 5, 2009 at 1:30 PM, Neil Schemenauer <nas at arctrix.com> wrote:

> What I would like to see is a module that provides a low-level API
> for doing cross-platform asynchronous IO.  The two necessary parts
> are:
>
>    * a wrapper that allows non-blocking reads and writes on
>      channels (sockets, file descriptors, serial ports, etc)
>
>    * a select() or epoll like interface that allows waiting on
>      multiple channels
>

Two thoughts:

If you have a working select(), it will tell you the sockets on which read()
and write() won't block, so non-blocking reads and writes are not necessary.

On Windows, sockets, pipes, and files are each completely distinct types
with their own functions and unifying them under one select()-like interface
requires faking it using threads behind-the-scenes AFAIK.  Personally, I'd
be happy with continuing to only support socket objects on Windows.

--
Daniel Stutzbach, Ph.D.
President, Stutzbach Enterprises, LLC <http://stutzbachenterprises.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20090305/8272c184/attachment.htm>


More information about the Python-Dev mailing list