def parent(): print "p" try: yield child() except Exception, e: print "parent caught", e yield bluelet.end(1)
def child(): print 'Child started.' yield bluelet.null() print 'Child resumed.' yield bluelet.null() print 'Child ending.' yield bluelet.end(42)