Python's requests with custom configuration
Project description
Module to work with custom requests capabilities.
Current capabilities configured:
- Custom timeout for all requests.
- Raise exception with certain HTTP status code responses.
- Retry on failure.
Installation
pip install requests_custom
How to use
from requests_custom import requests_custom
requests = requests_custom.RequestsCustom(debug_full = True).get_requests()
requests.get('https://duckduckgo.com')
References
https://findwork.dev/blog/advanced-usage-python-requests-timeouts-retries-hooks/
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
requests_custom-0.0.3.tar.gz
(3.5 kB
view hashes)
Built Distribution
Close
Hashes for requests_custom-0.0.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c6730efeec0b6a6ba54b4e62d398b4f3db0b10888161b82fd78cb27170cf39e7 |
|
MD5 | a42a42e7c636c79b91b22941b270b98d |
|
BLAKE2b-256 | 40be1539f3326fda589570f8aedda7d235ef253d249f2a10252cde28696e159e |