From cb653c5ef9e865b312da78a0c8d666ec7dd6043e Mon Sep 17 00:00:00 2001 From: Ben Darnell Date: Sun, 1 Dec 2013 15:04:02 -0500 Subject: [PATCH] Document the attributes required by @run_on_executor. Closes #933. --- tornado/concurrent.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tornado/concurrent.py b/tornado/concurrent.py index 9a10905e..a9002b16 100644 --- a/tornado/concurrent.py +++ b/tornado/concurrent.py @@ -151,6 +151,9 @@ def run_on_executor(fn): The decorated method may be called with a ``callback`` keyword argument and returns a future. + + This decorator should be used only on methods of objects with attributes + ``executor`` and ``io_loop``. """ @functools.wraps(fn) def wrapper(self, *args, **kwargs):