Skip to main content

zip operator for async iterables

Project description

Asynchronous ZIP Operator

The azip() function takes both synchronous and asynchronous iterables (can be zero or more), awaits their results one-by-one and aggregates them into a tuple. It stops if one of the iterators is exhausted. It waits for the next value of all iterators before yielding the tuple.

Installation

python -m pip install azip

Usage

from azip.azip import azip

async for s, a in azip(sync_iter, async_iter):
  print(s, a)

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

azip-1.0.1-py3-none-any.whl (3.0 kB view details)

Uploaded Python 3

File details

Details for the file azip-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: azip-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 3.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.6

File hashes

Hashes for azip-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 a26a488c273767d5c5bba8648994f70883d35178b68838ca9ae8342274f0efbb
MD5 900774c1571b53eac9b70d50a659fa6b
BLAKE2b-256 7a69a0a29d0ee42b9e004f318f6912d00107b030b241e59f96b47e1e928e7af3

See more details on using hashes here.

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