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-0.3.3.tar.gz
(4.0 kB
view hashes)
Built Distribution
Close
Hashes for threadloop-0.3.3-py2-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a417febcdf7f82437d06d21a74124d3bf527ee15161a2d8236ac2287def1c225 |
|
MD5 | 845f9b3534f24458bab4650734d7f184 |
|
BLAKE2b-256 | 54207291886e0f0efca2f114794fe25ec0ba7265a2f75105191ef86935be1c21 |