]> granicus.if.org Git - python/commit
bpo-33110: Catch errors raised when running add_done_callback on already completed...
authorSam Martin <ABitMoreDepth@users.noreply.github.com>
Wed, 22 May 2019 21:29:02 +0000 (22:29 +0100)
committerAntoine Pitrou <antoine@python.org>
Wed, 22 May 2019 21:29:02 +0000 (23:29 +0200)
commit2a3a2ece502c05ea33c95dd0db497189e0354bfd
tree76436af78c3c003166a1e4c353feb03c67314928
parentd8a82e2897b735e2b7e9e086f1d709365a2ad72c
bpo-33110: Catch errors raised when running add_done_callback on already completed futures (GH-13141)

Wrap the callback call within the `add_done_callback` function within concurrent.futures, in order to behave in an identical manner to callbacks added to a running future are triggered once it has completed.
Lib/concurrent/futures/_base.py
Lib/test/test_concurrent_futures.py
Misc/NEWS.d/next/Library/2019-05-06-22-34-47.bpo-33110.rSJSCh.rst [new file with mode: 0644]