Rate Limiting and Caching HTTPX Client
Project description
HTTPX Wrapper with Rate Limiting and Caching Transports.
Introduction
The goal of this project is convenience - leveraging existing rate limiting and caching libraries with a more convenient interface and abstract away certain decisions.
This came about while implementing caching & rate limiting for edgartools: reducing network requests and improving overall performance led to a rabbit hole of decisions. The SEC's Edgar site has a strict 10 request per second limit, while providing not-very-helpful caching headers. Overriding these caching headers with custom rules has a significant performance improvement.
Caching
This project builds on Hishel to provide:
-
Easily configurable File Storage and (TBD) AWS S3 Storage
-
Cache Controller driven by rules, defined as:
{ 'site_regex': { 'url_regex': duration } }
duration is int | bool:
- int: # of seconds to treat the file as unchanged: the file will not be revalidated during this period
- true: infinite caching - never re-validate
-
Rate Limiting supporting local rate limits, multiprocessing rate limiting, and distributed rate limiting.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file httpxthrottlecache-0.1.4.tar.gz.
File metadata
- Download URL: httpxthrottlecache-0.1.4.tar.gz
- Upload date:
- Size: 11.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
808b44488a513bae9cc08b10f03e14307b2f3fa9c7efe779725ccea1d5fe80a1
|
|
| MD5 |
a4d4213ebdbbf0ef9c8af6745891d4ec
|
|
| BLAKE2b-256 |
3c054e88c885be105b0dd06419b8454a6cbac4790bc8d97f47875b36a23efd46
|
Provenance
The following attestation bundles were made for httpxthrottlecache-0.1.4.tar.gz:
Publisher:
build_deploy.yml on paultiq/httpxthrottlecache
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
httpxthrottlecache-0.1.4.tar.gz -
Subject digest:
808b44488a513bae9cc08b10f03e14307b2f3fa9c7efe779725ccea1d5fe80a1 - Sigstore transparency entry: 376643876
- Sigstore integration time:
-
Permalink:
paultiq/httpxthrottlecache@7964ead7df27d0929e2d6f7dd7331ebbda097e35 -
Branch / Tag:
refs/tags/v0.1.4 - Owner: https://github.com/paultiq
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
build_deploy.yml@7964ead7df27d0929e2d6f7dd7331ebbda097e35 -
Trigger Event:
push
-
Statement type:
File details
Details for the file httpxthrottlecache-0.1.4-py3-none-any.whl.
File metadata
- Download URL: httpxthrottlecache-0.1.4-py3-none-any.whl
- Upload date:
- Size: 9.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e98a0fbca52905346942f472e87eca0a7a1b7e96d0690386ca5aff5bf746ca50
|
|
| MD5 |
7aa48b3093b5a6c887ba3c988b212d8a
|
|
| BLAKE2b-256 |
03869c75c98e0f9669289fbcaa2559d660c69bb62b03350e322384099ebeb157
|
Provenance
The following attestation bundles were made for httpxthrottlecache-0.1.4-py3-none-any.whl:
Publisher:
build_deploy.yml on paultiq/httpxthrottlecache
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
httpxthrottlecache-0.1.4-py3-none-any.whl -
Subject digest:
e98a0fbca52905346942f472e87eca0a7a1b7e96d0690386ca5aff5bf746ca50 - Sigstore transparency entry: 376643882
- Sigstore integration time:
-
Permalink:
paultiq/httpxthrottlecache@7964ead7df27d0929e2d6f7dd7331ebbda097e35 -
Branch / Tag:
refs/tags/v0.1.4 - Owner: https://github.com/paultiq
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
build_deploy.yml@7964ead7df27d0929e2d6f7dd7331ebbda097e35 -
Trigger Event:
push
-
Statement type: