diff --git a/README.md b/README.md index ff11391..5badded 100644 --- a/README.md +++ b/README.md @@ -12,9 +12,9 @@ Small sync helpers shared across projects. Base is stdlib only — **no dependen ## Install ``` -commons @ git+ssh://git@git.rethinkstudios.io/rethink-public/commons.git@v0.2.0 +commons @ git+ssh://git@git.rethinkstudios.io/rethink-public/commons.git@v0.2.1 # async address/geo lookups (fetch_ip / ip_location / fetch_location) need the extra: -commons[addr] @ git+ssh://git@git.rethinkstudios.io/rethink-public/commons.git@v0.2.0 +commons[addr] @ git+ssh://git@git.rethinkstudios.io/rethink-public/commons.git@v0.2.1 ``` The base install pulls **nothing** (stdlib). Only `commons[addr]` adds `aiohttp`, and diff --git a/src/commons/retry.py b/src/commons/retry.py index 257669b..d12ecb2 100644 --- a/src/commons/retry.py +++ b/src/commons/retry.py @@ -96,7 +96,7 @@ def retry( wait = _jittered(delays[index], jitter, rand) log.warning( "retry %d/%d after %s: %s", - index + 1, last_index, type(exc).__name__, exc, + index + 1, attempts, type(exc).__name__, exc, ) if wait > 0: sleep(wait) @@ -149,7 +149,7 @@ def aretry( wait = _jittered(delays[index], jitter, rand) log.warning( "retry %d/%d after %s: %s", - index + 1, last_index, type(exc).__name__, exc, + index + 1, attempts, type(exc).__name__, exc, ) if wait > 0: await sleep(wait)