This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author rhettinger
Recipients
Date 2004-04-30.22:58:02
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
Logged In: YES 
user_id=80475

For the record, here a simple and efficient roundrobin task
server based on collections.deque:

def roundrobin(*iterables):
    pending = deque(iter(i).next for i in iterables)
    gettask, scheduletask = pending.popleft, pending.append
    while pending:
        task = gettask()
        try:
            yield task()
        except StopIteration:
            continue
        scheduletask(task)

for value in roundrobin('abc', 'd', 'efgh'):
    print value
History
Date User Action Args
2007-08-23 15:27:51adminlinkissue756253 messages
2007-08-23 15:27:51admincreate