Skip to main content

Allow non-async defs that invoke awaitables inside of asyncio applications

Project description

Allow non-async defs that invoke awaitables inside of asyncio applications.

awaitlet allows existing programs written to use threads and blocking APIs to be ported to asyncio, by replacing frontend and backend code with asyncio compatible approaches, but allowing intermediary code to remain completely unchanged. Its primary use is to support code that is cross-compatible with asyncio and non-asyncio runtime environments.

awaitlet is intentionally fully compatible with SQLAlchemy’s asyncio mediation layer, and includes API patterns for:

  • Converting any threaded program (no SQLAlchemy dependency necessary) to use asyncio patterns for front facing APIs and backends, without modifying intermediary code

  • Converting threaded database-enabled programs to use asyncio patterns for front facing APIs and backends, where those backends use SQLAlchemy’s asyncio API for database access

  • Converting threaded database-enabled programs to use asyncio patterns for front facing APIs and backends, without modifying intermediary code that uses SQLAlchemy’s synchronous API for database access

Documentation for awaitlet is within this source distribution and availble on the web at https://awaitlet.sqlalchemy.org .

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

awaitlet-0.0.1.tar.gz (67.2 kB view hashes)

Uploaded Source

Built Distribution

awaitlet-0.0.1-py3-none-any.whl (82.5 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