Skip to content

abranjith/unblock

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ac7b410 · Nov 6, 2024

History

54 Commits
Aug 18, 2024
Sep 16, 2024
Nov 6, 2024
Sep 16, 2024
Jan 5, 2021
Aug 18, 2024
Aug 18, 2024
Oct 8, 2020
Aug 18, 2024
Sep 16, 2024
Aug 19, 2024
Aug 18, 2024
Aug 19, 2024

Repository files navigation

unblock

unblock comes with utilities that can be used to convert synchronous functions to async for use in event loop. For documentation, refer here

Here is a quick example,

import asyncio
from unblock import asyncify
   
@asyncify
def my_sync_func():
   #do something

if __name__ == "__main__":
   asyncio.run(my_sync_func())

Release Notes:

0.0.1

Features,

  • Convert your synchronous functions, methods etc. to asynchronous with easy to use constructs
  • Asynchronous tasks are started in the background without the need of await keyword. Note that await is still needed to fetch results
  • By default uses even loop provided by asyncio. But supports other event loops as well
  • Support for ThreadPool or ProcessPool executors
  • Comes with APIs to build your own asynchronous context manager, asynchronous iterators etc.
  • Supports python 3.7 and above

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages