Registry / aws / awsretry

awsretry

JSON →
library1.0.2pypypiunverified

A decorator for AWS Boto3 calls that automatically retries on eventual consistency errors. Version 1.0.2 is current; release cadence is low (last release Apr 2019).

pip install awsretry
INSTALL
IMPORT
SIG · AWSRETRY
A
awsretry
awspythonv1.0.2
Install
4.5s avg
Import
748ms
Disk
61MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v1.0.1 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.95 runs
installs and imports cleanly · install 0.0s · import 0.488s · 61.6MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 4.5s · import 0.410s · 62MB
61MB installed
● package 61MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

AWSRetry
from awsretry import AWSRetry
Standard import path.
backoff
from awsretry import backoff @backoff()
backoff is a decorator factory, call it to get the decorator.

Decorate a Boto3 call to retry on AWS eventual consistency errors.

import boto3 from awsretry import AWSRetry @AWSRetry.backoff() def describe_instance(instance_id): client = boto3.client('ec2', region_name='us-east-1') return client.describe_instances(InstanceIds=[instance_id]) describe_instance('i-12345678')
Debug
Known issues
gotchaThe library only retries on specific error codes related to eventual consistency (e.g., 'Throttling', 'RequestLimitExceeded'). It does not retry on all boto3 exceptions.
fix
If you need retry on other errors, consider using botocore's built-in retry mode or tenacity.
affects: all
deprecatedThe library has not been updated since 2019. Boto3's built-in retry behavior (via botocore config) has improved significantly.
fix
Prefer using botocore's retry configuration: boto3.client('ec2', config=Config(retries={'max_attempts': 10, 'mode': 'adaptive'}))
affects: >=1.0.0
gotchaThe decorator must be applied to a function that returns a boto3 service response directly; it does not support async functions.
fix
Ensure decorated function is synchronous and returns a boto3 API call result.
affects: all
Upgrade
Version history
1.0.2latest on PyPI
Audit
Dependencies
boto3requiredAWS SDK used for API calls
Agent activity
31 hits · last 30 days
node
28
Amazon
1
OpenAI (training)
1
Resources
awsretry — pip install awsretry · libregistry