A Python library that make HTTP requests with exponential back-off retry by using requests package.
Project Links
Meta
Author: Tsuyoshi Hombashi
Requires Python: >=3.6
Classifiers
Development Status
- 4 - Beta
Intended Audience
- Information Technology
License
- OSI Approved :: MIT License
Operating System
- OS Independent
Programming Language
- Python :: 3
- Python :: 3.6
- Python :: 3.7
- Python :: 3.8
- Python :: 3.9
- Python :: 3.10
Topic
- Software Development :: Libraries
- Software Development :: Libraries :: Python Modules
Summary
A Python library that make HTTP requests with exponential back-off retry by using requests package.
Installation
pip install retryrequests
Usage
retryrequests has same interface with requests:
- Sample Code:
import json import retryrequests r = retryrequests.get("https://kctbh9vrtdwd.statuspage.io/api/v2/status.json") r.raise_for_status() print(json.dumps(r.json(), indent=4))- Output:
{ "page": { "id": "kctbh9vrtdwd", "name": "GitHub", "url": "https://www.githubstatus.com", "time_zone": "Etc/UTC", "updated_at": "2019-03-30T07:11:24.851Z" }, "status": { "indicator": "none", "description": "All Systems Operational" } }
Dependencies
Python 3.6+
Wheel compatibility matrix
Files in release
Extras:
None
Dependencies:
requests
(<3.0.0,>=2.18.4)