작성
·
196
답변 1
0
concurrent.futures.
wait
(fs, timeout=None, return_when=ALL_COMPLETED)
Wait for the Future
instances (possibly created by different Executor
instances) given by fs to complete. Returns a named 2-tuple of sets. The first set, named done
, contains the futures that completed (finished or cancelled futures) before the wait completed. The second set, named not_done
, contains the futures that did not complete (pending or running futures).
맞습니다.
2개의 튜플이고 첫 번째 Set은 완료된 future, 두 번째 Set은 pending 또는 실행중인 future를
반환합니다.
보통은 메소드처럼 사용한다기 보다는 futures 담긴 작업들이 종료되기를 대기할 때 사용합니다.