Tulip is the codename for my attempt at understanding PEP-380 style
coroutines (i.e. those using generators and 'yield from').  

*** This requires Python 3.3 or later! ***

For reference, see many threads in started in
October 2012, especially those with "The async API of the Future" in
their subject, and the various spin-off threads.

A particularly influential tutorial by Greg Ewing:

A message I posted with some explanation of the design:

Essential files here (in top-to-bottom ordering):

- the main program for testing
- a rough HTTP/1.0 client
- transports for sockets and (client) SSL, and a buffering layer
- a Task class and related stuff; this is where the PEP
  380 scheduler is implemented
- an event loop and basic polling implementations for:
  select(), poll(), epoll(), kqueue()

Secondary files:

- .hgignore: files I don't care about
- Makefile: various quick shell commands
- README: this file
- TODO: longer list of TODO items and general thoughts
- enough of an HTTP server to point 'ab' at
- stupid style checker
- benchmark yield from vs. plain functions
- yet another benchmark (like and
- *synchronous* ssl example
- benchmark yield from vs. yield <future>

Copyright/license: Open source, Apache 2.0.  Enjoy.

Master Mercurial repo:

--Guido van Rossum <>