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.0.tar.gz
(4.6 kB
view hashes)
Built Distribution
Close
Hashes for threadloop-1.0.0-py2-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 07fa80a9b167f407285a320917a48385f88c50bd50ba626ab3e52b7ac56bd611 |
|
MD5 | 914ba01403a4f5f89cacdbe5b4cc79af |
|
BLAKE2b-256 | a221c006af921e21ca8f0fcc847b989ee1284193b7efb1bba1480cca07232858 |