Catalog PyPI
PACKAGE EXPLORERView in registry

aioburst

PyPI

A library to optimize the speed of rate limited async calls.

Versions collected1
Direct dependencies2From release 0.2.0
Last observed21 Oct, 11:42 UTC

README

Version 0.2.0 documentation

aioburst

A library to optimize the speed of rate limited async calls, by alternating between bursts and sleeps.

Usage

Install the package using pip:

pip install aioburst

Import the limiter:

from aioburst import aioburst

Instantiate the limiter using the create method, setting the limit (number of calls) and period (period over which the number of calls are restricted):

limiter = AIOBurst.create(limit=10, period=1.0)

async with limiter:
    ...

The code above would allow 10 asynchronous entries (into the context manager) without any limit. Then it adds "sleepers" for the next calls. The sleeper tells the next entry when it can start. The 11th call gets the sleeper set by the 1st call that returned and waits until the period has elapsed. This approach ensures that there are never more than limit simultaneous calls but that the next call can start as soon as possible. The result is that in a sliding window of period you should see exactly limit calls as active, regardless of how fast or slow any individual call returns.

You can also stack limiters:

limiter1 = AIOBurst.create(limit=10, period=1.0)
limiter2 = AIOBurst.create(limit=100, period=60.0)

async with limiter1:
	async with limiter2:
    ...

Use this for cases where an API has a two-level rate limit like 10 calls per second or 100 calls per minute---both limits will be respected. The stack is also idempotent, meaning that whichever way you stack the limiters, both limits will be respected:

limiter1 = AIOBurst.create(limit=10, period=1.0)
limiter2 = AIOBurst.create(limit=100, period=60.0)


async with limiter1:
	async with limiter2:
    ...
    
# The limit above will do the exact same thing as the limit below
async with limiter2:
	async with limiter1:
    ...

Downloads & popularity

2downloads
1-day window · source-reported counts20 Oct 2026
840
2026-07-23: 3 · observed 2026-10-21T17:46:32.9351056Z · period 2026-07-23–2026-07-232026-07-24: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-07-24–2026-07-242026-07-27: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-07-27–2026-07-272026-07-28: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-07-28–2026-07-282026-08-01: 8 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-01–2026-08-012026-08-02: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-02–2026-08-022026-08-03: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-03–2026-08-032026-08-05: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-05–2026-08-052026-08-09: 4 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-09–2026-08-092026-08-14: 3 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-14–2026-08-142026-08-15: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-15–2026-08-152026-08-17: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-17–2026-08-172026-08-19: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-19–2026-08-192026-08-21: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-21–2026-08-212026-08-22: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-22–2026-08-222026-08-23: 3 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-23–2026-08-232026-08-24: 5 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-24–2026-08-242026-08-25: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-25–2026-08-252026-08-26: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-26–2026-08-262026-08-27: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-27–2026-08-272026-08-28: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-28–2026-08-282026-08-29: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-29–2026-08-292026-08-31: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-08-31–2026-08-312026-09-01: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-09-01–2026-09-012026-09-02: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-09-02–2026-09-022026-09-04: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-09-04–2026-09-042026-09-07: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-09-07–2026-09-072026-09-12: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-09-12–2026-09-122026-09-22: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-09-22–2026-09-222026-09-23: 3 · observed 2026-10-21T17:46:32.9351056Z · period 2026-09-23–2026-09-232026-09-25: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-09-25–2026-09-252026-09-26: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-09-26–2026-09-262026-09-27: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-09-27–2026-09-272026-09-28: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-09-28–2026-09-282026-09-30: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-09-30–2026-09-302026-10-02: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-10-02–2026-10-022026-10-03: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-10-03–2026-10-032026-10-04: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-10-04–2026-10-042026-10-06: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-10-06–2026-10-062026-10-08: 7 · observed 2026-10-21T17:46:32.9351056Z · period 2026-10-08–2026-10-082026-10-09: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-10-09–2026-10-092026-10-10: 6 · observed 2026-10-21T17:46:32.9351056Z · period 2026-10-10–2026-10-102026-10-11: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-10-11–2026-10-112026-10-13: 1 · observed 2026-10-21T17:46:32.9351056Z · period 2026-10-13–2026-10-132026-10-17: 3 · observed 2026-10-21T17:46:32.9351056Z · period 2026-10-17–2026-10-172026-10-19: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-10-19–2026-10-192026-10-20: 2 · observed 2026-10-21T17:46:32.9351056Z · period 2026-10-20–2026-10-20
23 Jul20 Oct

pypistats · 47 observations shown. Missing days are unknown. Source category: overall: without mirrors.

View observed values
Date / source periodValueObserved at
2026-10-20 – 2026-10-2022026-10-21T17:46:32.9351056Z
2026-10-19 – 2026-10-1922026-10-21T17:46:32.9351056Z
2026-10-17 – 2026-10-1732026-10-21T17:46:32.9351056Z
2026-10-13 – 2026-10-1312026-10-21T17:46:32.9351056Z
2026-10-11 – 2026-10-1112026-10-21T17:46:32.9351056Z
2026-10-10 – 2026-10-1062026-10-21T17:46:32.9351056Z
2026-10-09 – 2026-10-0912026-10-21T17:46:32.9351056Z
2026-10-08 – 2026-10-0872026-10-21T17:46:32.9351056Z
2026-10-06 – 2026-10-0612026-10-21T17:46:32.9351056Z
2026-10-04 – 2026-10-0412026-10-21T17:46:32.9351056Z
2026-10-03 – 2026-10-0312026-10-21T17:46:32.9351056Z
2026-10-02 – 2026-10-0222026-10-21T17:46:32.9351056Z
2026-09-30 – 2026-09-3022026-10-21T17:46:32.9351056Z
2026-09-28 – 2026-09-2822026-10-21T17:46:32.9351056Z
2026-09-27 – 2026-09-2712026-10-21T17:46:32.9351056Z
2026-09-26 – 2026-09-2622026-10-21T17:46:32.9351056Z
2026-09-25 – 2026-09-2522026-10-21T17:46:32.9351056Z
2026-09-23 – 2026-09-2332026-10-21T17:46:32.9351056Z
2026-09-22 – 2026-09-2212026-10-21T17:46:32.9351056Z
2026-09-12 – 2026-09-1212026-10-21T17:46:32.9351056Z
2026-09-07 – 2026-09-0722026-10-21T17:46:32.9351056Z
2026-09-04 – 2026-09-0412026-10-21T17:46:32.9351056Z
2026-09-02 – 2026-09-0222026-10-21T17:46:32.9351056Z
2026-09-01 – 2026-09-0112026-10-21T17:46:32.9351056Z
2026-08-31 – 2026-08-3112026-10-21T17:46:32.9351056Z
2026-08-29 – 2026-08-2912026-10-21T17:46:32.9351056Z
2026-08-28 – 2026-08-2812026-10-21T17:46:32.9351056Z
2026-08-27 – 2026-08-2722026-10-21T17:46:32.9351056Z
2026-08-26 – 2026-08-2612026-10-21T17:46:32.9351056Z
2026-08-25 – 2026-08-2522026-10-21T17:46:32.9351056Z
2026-08-24 – 2026-08-2452026-10-21T17:46:32.9351056Z
2026-08-23 – 2026-08-2332026-10-21T17:46:32.9351056Z
2026-08-22 – 2026-08-2212026-10-21T17:46:32.9351056Z
2026-08-21 – 2026-08-2112026-10-21T17:46:32.9351056Z
2026-08-19 – 2026-08-1912026-10-21T17:46:32.9351056Z
2026-08-17 – 2026-08-1722026-10-21T17:46:32.9351056Z
2026-08-15 – 2026-08-1522026-10-21T17:46:32.9351056Z
2026-08-14 – 2026-08-1432026-10-21T17:46:32.9351056Z
2026-08-09 – 2026-08-0942026-10-21T17:46:32.9351056Z
2026-08-05 – 2026-08-0522026-10-21T17:46:32.9351056Z
2026-08-03 – 2026-08-0322026-10-21T17:46:32.9351056Z
2026-08-02 – 2026-08-0212026-10-21T17:46:32.9351056Z
2026-08-01 – 2026-08-0182026-10-21T17:46:32.9351056Z
2026-07-28 – 2026-07-2812026-10-21T17:46:32.9351056Z
2026-07-27 – 2026-07-2722026-10-21T17:46:32.9351056Z
2026-07-24 – 2026-07-2412026-10-21T17:46:32.9351056Z
2026-07-23 – 2026-07-2332026-10-21T17:46:32.9351056Z

Versions 1

Collected releases
VersionPublishedDirect dependenciesOpen version
0.2.020 Oct 20222

Package advisories

0
No matching advisories collected

This describes our collected data; it is not a security assessment.

Metadata history

Meaningful changes
Current collected state Current

Observed since 21 Oct, 11:42 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package:2b8d70c4b66f0b0f1c4fc16022a5549742190606dc5ee89e1f28a4f69f184101