skillfed

rush

A library for throttling algorithms

rush v2021.4.0 299.4K downloads/30d#7,860 on PyPI65
Permissive license MIT Abandoned released

What it is and what it does

rush is a small, focused library for implementing rate-limiting and throttling logic in Python applications. It provides two main algorithms—a basic periodic interval limiter and a leaky bucket rate limiter based on GCRA—along with pluggable storage backends so you can choose between Redis for distributed state or an in-memory dictionary for testing and prototyping. The library is fully typed, well-tested, and documented.

The package is designed to be algorithm-agnostic and storage-agnostic, meaning you can mix and match limiters and backends without worrying about compatibility. It's useful when you need to enforce rate limits on API calls, user interactions, or other resource access patterns. However, the project has been abandoned since early 2021 with no active maintenance, so it will not receive bug fixes, security patches, or updates for newer Python versions.

Use it for:

  • Enforce rate limits on outbound API calls to third-party services.
  • Throttle user requests in a web application to prevent abuse or resource exhaustion.
  • Implement distributed rate limiting across multiple application instances using a Redis backend.
  • Prototype and test rate-limiting logic quickly using the in-memory storage backend.
  • Add request throttling to a CLI tool or batch job that interacts with rate-limited APIs.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

rush provides rate-limiting algorithms (periodic interval and leaky bucket GCRA) with pluggable storage backends (Redis or in-memory) for throttling access to resources like APIs.

Yes, if you need a simple, well-typed rate-limiting library and can accept that it will not receive updates. The code is stable and production-ready (Development Status 5), has no known vulnerabilities, and low install friction. However, do not use it if you require active maintenance, security patches, or support for Python versions beyond 3.7.

Install

rush on PyPI

pip

pip install rush

uv

uv add rush

poetry

poetry add rush

Installing rush

Before you install

Low install friction with a single runtime dependency (attrs). However, the package is abandoned—last release was 2021-04-01 and last commit 2023-03-27—so no maintenance or security updates are forthcoming.

License in practice

MIT license is permissive, allowing commercial and private use with minimal restrictions, making it safe from a licensing perspective for most projects.

Quickstart

pip install rush

from rush.limiters import Limiter
from rush.stores import MemoryStore

store = MemoryStore()
limiter = Limiter(store, max_attempts=5)
if limiter.try_acquire('user_id'):
    # Allow request
    pass

Requires Python 3.6 or later. Redis backend requires additional redis and rfc3986 dependencies if using Redis storage instead of in-memory.

Verify before relying

  • Whether the package works reliably with Python versions beyond 3.7 (classifiers only list 3.6 and 3.7, but requires_python says >=3.6)
  • Whether abandonment and lack of maintenance since 2021 poses compatibility risks with modern Python or dependency ecosystems
  • Specific rate-limit interval values and configuration defaults for the periodic interval and GCRA limiters

Package facts

License MIT (permissive)
Python support supports the current Python release (>=3.6)
Install friction low — pure-Python wheel
Runtime dependencies 1 — attrs
Maintenance abandoned — 1,961 days since the last release
Last repo commit
First released
Downloads 299,368/month — #7,860 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: rush-2021.4.0-py3-none-any.whl

Keywords: throttles, throttle, algorithm, gcra, redis

Development Status :: 5 - Production/StableEnvironment :: ConsoleIntended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseProgramming Language :: PythonProgramming Language :: Python :: 3.6Programming Language :: Python :: 3.7

Tags

rate limiting librarythrottle algorithmapi rate limiterleaky bucket gcraredis rate limitrequest throttlingperiodic interval limiter
rate-limitingthrottlingapi-control

More Internet packages