[New-bugs-announce] [issue11724] concurrent.futures: executor.submit() runs until completion even when future times out or is canceled

jenisys report at bugs.python.org
Wed Mar 30 23:00:09 CEST 2011


New submission from jenisys <jens_engel at web.de>:

A long running task that is submitted to an ThreadPoolExecutor runs to completion even when the future times out or is canceled.
Even executor.shutdown(wait=False) will not help.

HOW TO REPEAT:
Provide a function which sleeps for 10 seconds.
Submit it to a ThreadPoolExecutor.
Wait on the future for the  result for 2 seconds.

OBSERVED BEHAVIOUR:
1. future times out after approx. 2 seconds
2. Process shutdown is delayed by an additional 8 seconds,
   meaning it waits until submitted task/function has completed.

----------
components: Library (Lib)
messages: 132614
nosy: jenisys
priority: normal
severity: normal
status: open
title: concurrent.futures: executor.submit() runs until completion even when future times out or is canceled
type: behavior
versions: Python 3.2

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue11724>
_______________________________________


More information about the New-bugs-announce mailing list