epsy / clize

CLIze: Turn Python functions into command-line interfaces
http://clize.readthedocs.io/
MIT License
480 stars 26 forks source link

Add asyncio bootstrapper decorator #27

Open epsy opened 7 years ago

epsy commented 7 years ago

The decorator would allow the use of async functions by running them using loop.run_until_complete. This should be implemented in a way that doesn't prevent execution if asyncio isn't present. (import within the decorator will do)

piranna commented 6 months ago

Any update on this?

piranna commented 6 months ago

Myself i'm using asyncio.run(), that's a higher level API. I think that's the one we should be using here.