1# Copyright 2009 Brian Quinlan. All Rights Reserved. 2# Licensed to PSF under a Contributor Agreement. 3 4"""Execute computations asynchronously using threads or processes.""" 5 6__author__ = 'Brian Quinlan (brian@sweetapp.com)' 7 8from concurrent.futures._base import (FIRST_COMPLETED, 9 FIRST_EXCEPTION, 10 ALL_COMPLETED, 11 CancelledError, 12 TimeoutError, 13 Future, 14 Executor, 15 wait, 16 as_completed) 17from concurrent.futures.process import ProcessPoolExecutor 18from concurrent.futures.thread import ThreadPoolExecutor 19