Decorator for retrying exec a method
Project description
# `retry` decorator
[![Build Status](https://travis-ci.org/soasme/retries.png?branch=master)](https://travis-ci.org/soasme/retries)
A dead simple way to retry your method.
Through source code:
git clone git://github.com/soasme/retries.git
cd retries
python setup.py install
Usage:
from retry import retry
@retry(errors=(urllib2.URLError), tries=3, delay=3.5)
def fetch_page():
pass
@retry(errors=(TTransportException, ), delay=0.1)
def thrift_call():
pass
[![Build Status](https://travis-ci.org/soasme/retries.png?branch=master)](https://travis-ci.org/soasme/retries)
A dead simple way to retry your method.
Through source code:
git clone git://github.com/soasme/retries.git
cd retries
python setup.py install
Usage:
from retry import retry
@retry(errors=(urllib2.URLError), tries=3, delay=3.5)
def fetch_page():
pass
@retry(errors=(TTransportException, ), delay=0.1)
def thrift_call():
pass
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
retries-1.0.tar.gz
(2.5 kB
view details)
File details
Details for the file retries-1.0.tar.gz
.
File metadata
- Download URL: retries-1.0.tar.gz
- Upload date:
- Size: 2.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 84de6c78cf29efddacc1597cb2aa06b29e43e63883b8fd8a4fbe280e18044f43 |
|
MD5 | 0c5058fd794465fd3bfd3fd2631ea024 |
|
BLAKE2b-256 | 4e5c9e1f690e533eaaffbb88e0de81950ef4ec345a2a7f96a871809b8c55fd17 |