Configurable elegant retrying.
Project description
Retrace your steps and try again.
Retrace provides a configurable decorator which allows you to wrap Python callables and retry them on errors or other specific conditions.
Docs
It is simple and elegant.
See the documentation at:
http://d0ugal.github.io/retrace/
Quickstart
First, pip install retrace.
import retrace
@retrace.retry
def unstable():
# ...
Boom. Done.
This function will now be retied up to 5 times if it raises an exception. You can customise how often it is retried, limit the exceptions and add validators to further verify the return value. Check out the docs for all this and more.
Project details
Release history Release notifications | RSS feed
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 retrace-3.0.0.tar.gz.
File metadata
- Download URL: retrace-3.0.0.tar.gz
- Upload date:
- Size: 11.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8774db5399ab056bb473052f7393449ca6e43ac610f9f3180fb88050ff2fc06b
|
|
| MD5 |
21215633067d35aa024690c89981876b
|
|
| BLAKE2b-256 |
ce8293386fa728885e74fd620438c33deaeae363173ed4006fdd0cf0d5506872
|
File details
Details for the file retrace-3.0.0-py2.py3-none-any.whl.
File metadata
- Download URL: retrace-3.0.0-py2.py3-none-any.whl
- Upload date:
- Size: 5.8 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
472eee78292ff8c68c1243908d6cd392fa1af30109e6cf2f4510490990dc8983
|
|
| MD5 |
9ee9cca2b1dd79991d54604043261589
|
|
| BLAKE2b-256 |
3d0f11f39d7643693a51b57f038d98d318f763f26c1c653665ad389fd468ed27
|