Skip to content

Instantly share code, notes, and snippets.

View gist:275d02f69e686baa9aebf5688c0b6d65
from collections import deque
results = deque(pool.apply_async(...) for job in jobs)
while results:
current = results.popleft()
try:
current_result = current.get(0.1)
process(current_result)
You can’t perform that action at this time.