From dc17c8824e087c7434ed2a88f420a4304090672b Mon Sep 17 00:00:00 2001 From: Joshua Harlow Date: Fri, 31 Mar 2017 22:56:06 -0700 Subject: [PATCH] Expose underlying timeout error This makes it easier to use the other various functions in futures or executors that will raise this when they timeout. Change-Id: If18d55fc20b2cb6a919c9a1a98a818f4068bd3ec --- futurist/__init__.py | 1 + futurist/_futures.py | 1 + 2 files changed, 2 insertions(+) diff --git a/futurist/__init__.py b/futurist/__init__.py index f7f874b..19aa6dc 100644 --- a/futurist/__init__.py +++ b/futurist/__init__.py @@ -20,6 +20,7 @@ from futurist._futures import Future # noqa from futurist._futures import GreenFuture # noqa from futurist._futures import CancelledError # noqa +from futurist._futures import TimeoutError # noqa from futurist._futures import GreenThreadPoolExecutor # noqa from futurist._futures import ProcessPoolExecutor # noqa diff --git a/futurist/_futures.py b/futurist/_futures.py index d3dd105..0f99fe3 100644 --- a/futurist/_futures.py +++ b/futurist/_futures.py @@ -28,6 +28,7 @@ from futurist import _thread from futurist import _utils +TimeoutError = _futures.TimeoutError CancelledError = _futures.CancelledError