[docs] [issue21376] asyncio docs refer to wrong TimeoutError

Antoine Pitrou report at bugs.python.org
Mon Apr 28 21:20:55 CEST 2014


Antoine Pitrou added the comment:

Gasp. Perhaps concurrent.futures.TimeoutError can inherit from the standard TimeoutError? The following patch doesn't seem to disrupt the test suite:

diff --git a/Lib/concurrent/futures/_base.py b/Lib/concurrent/futures/_base.py
--- a/Lib/concurrent/futures/_base.py
+++ b/Lib/concurrent/futures/_base.py
@@ -49,7 +49,7 @@ class CancelledError(Error):
     """The Future was cancelled."""
     pass
 
-class TimeoutError(Error):
+class TimeoutError(Error, TimeoutError):
     """The operation exceeded the given deadline."""
     pass

----------
assignee: docs at python -> 
components: +Library (Lib)
nosy: +giampaolo.rodola, gvanrossum, haypo, pitrou, yselivanov

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


More information about the docs mailing list