Tornado IOLoop Backed Concurrent Futures
Project description
Run Tornado Coroutines from Synchronous Python.
from threadloop import ThreadLoop
from tornado import gen
@gen.coroutine
def coroutine(greeting="Goodbye"):
yield gen.sleep(1)
raise gen.Return("%s World" % greeting)
with ThreadLoop() as threadloop:
future = threadloop.submit(coroutine, "Hello")
print future.result() # Hello World
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
threadloop-1.0.1.tar.gz
(4.8 kB
view hashes)
Built Distribution
Close
Hashes for threadloop-1.0.1-py2-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 45946ecb185eed84da38930d2d059f1a8685885b17f8d309529fc83e924db5e7 |
|
MD5 | 3296fe7277b21531463b8824b7c74dda |
|
BLAKE2b-256 | 90820e3184d9f6d165ceb031395cea75cea7af0b0af8526c69cb2b0b0c681bd7 |