A Python rate limiter based on Redis using a sliding window algorithm. It provides a decorator and context manager to limit the rate of function calls or code blocks. Version 0.0.10 is the latest release, with no recent updates; the package appears to be in maintenance mode.
pip install python-redis-rate-limitNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Basic usage of the rate_limit decorator, limiting to 10 calls per 60 seconds.
Wrap decorated calls in try-except or implement a fallback mechanism (e.g., check Redis availability before decorating).
Upgrade to Python 3 and use v0.0.9 or later.
Instantiate a new rate limiter object locally or ensure only one Redis instance is used. Check the source code for details.