Skip to main content

Asyncio version of concurrent.futures.Executor

Project description

aiolibs-executor

Asyncio version of concurrent.futures executor.

Installaion

pip install aiolibs-executor

Usage

from aiolibs_executor import Executor

async def worker(arg):
   return await do_stuff(arg)

async with Executor(num_workers=3) as executor:
	futs = [await executor.submit(worker(i)) for i in range(10)]
	for fut in futs:
		print(await fut)

All submitted worker(i) coroutines are distributed to three concurrent streams, awaiting returned functions provides a value returned by a coroutine.

TODO: Make comprehensive description of all public Executor's methods.

License

The library is published under Apache 2.0 license.

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

aiolibs_executor-0.0.0.tar.gz (8.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

aiolibs_executor-0.0.0-py3-none-any.whl (8.7 kB view details)

Uploaded Python 3

File details

Details for the file aiolibs_executor-0.0.0.tar.gz.

File metadata

  • Download URL: aiolibs_executor-0.0.0.tar.gz
  • Upload date:
  • Size: 8.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for aiolibs_executor-0.0.0.tar.gz
Algorithm Hash digest
SHA256 305d4dbf06006e1d4b1aad704bc4cbb71aad6c6cf4d93e83351e9e7e0bc45cf8
MD5 993c3ef2a451878784ab94f019344f91
BLAKE2b-256 a6b2ba769bcc2ef56260f932f765a9cc768c87435aaf202fdb5731ea237e1010

See more details on using hashes here.

Provenance

The following attestation bundles were made for aiolibs_executor-0.0.0.tar.gz:

Publisher: ci.yaml on aio-libs/aiolibs-executor

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file aiolibs_executor-0.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for aiolibs_executor-0.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 cdc3e31e1d96754007d28db07563a903caa5b2299cd968e430428f6cd97d8cbe
MD5 9727bb1db6996b4932c3a0ea417a5b30
BLAKE2b-256 6d7acd175ea8e8f2277709fa070372b7ca0dae039335e9f3911251b88ce7f673

See more details on using hashes here.

Provenance

The following attestation bundles were made for aiolibs_executor-0.0.0-py3-none-any.whl:

Publisher: ci.yaml on aio-libs/aiolibs-executor

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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