Skip to main content

async helper library.

Project description

When it comes to actually using the async features and the asyncio library in a real project, you don’t want to have to constantly worry about what thread you’re running in, what loop is global and whether or not it’s running. You don’t want to and shouldn’t have to worry about whether asyncio or some other async library (like curio) is running in a higher or lower level than your current abstraction layer in order to use asyncio and await syntax correctly.

This library provides simple functions for:

  • running an async function from a blocking context

  • running a blocking function from an async context

  • running a blocking function in the background

  • running multiple functions in parallel, either asynchronously or in a blocking fashion

  • running multiple functions in series, either asynchronously or in a blocking fashion

  • getting/creating and setting/reverting an independent asyncio event loop to use, regardless of thread or thread-global asyncio loop run status.

See the project site for examples, API doc, and more discussion.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

a_sync-0.3.0.tar.gz (6.3 kB view hashes)

Uploaded Source

Built Distribution

a_sync-0.3.0-py3-none-any.whl (8.6 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page