Dallas Marlow <dallasmar...@gmail.com> added the comment:
After closer inspection it seems as though timeouts are not working as I would expect even when there are no undefined references. The following code runs for 30s when I would expect a timeout exception thrown after 1 second. as_completed eventually does throw a timeout exception, but only after the sleep future completes. ############################### import concurrent.futures import time with concurrent.futures.ThreadPoolExecutor() as ex: futures = [ ex.submit(time.sleep, 30), ex.submit(print, 'test'), ] for future in concurrent.futures.as_completed(futures, timeout=1): _ = future.result() ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue41694> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com