]> granicus.if.org Git - python/commit
bpo-33097: Fix submit accepting callable after executor shutdown by interpreter exit...
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Tue, 10 Apr 2018 18:35:02 +0000 (11:35 -0700)
committerAntoine Pitrou <pitrou@free.fr>
Tue, 10 Apr 2018 18:35:02 +0000 (20:35 +0200)
commitb26265900a18a184997c3c3a1fa6a5bf29703ec9
treebb4852fb29034d3fbe1255106d6e87ed8e713a68
parent9bb8cebdce99db7e7a94f15141a8e0514b51aa72
bpo-33097: Fix submit accepting callable after executor shutdown by interpreter exit (GH-6144) (GH-6445)

Executors in concurrent.futures accepted tasks after executor was shutdown by interpreter exit. Tasks were left in PENDING state forever. This fix changes submit to instead raise a RuntimeError.
(cherry picked from commit c4b695f85e141f57d22d8edf7bc2c756da136918)

Co-authored-by: Mark Nemec <mrknmc@me.com>
Lib/concurrent/futures/process.py
Lib/concurrent/futures/thread.py
Lib/test/test_concurrent_futures.py
Misc/NEWS.d/next/Library/2018-03-18-16-48-23.bpo-33097.Yl4gI2.rst [new file with mode: 0644]