Skip to content

Commit edbcf6c

Browse files
fix: Add exception to the typing-only Details dictionary for cases when on_exception is used
1 parent 74d0fb1 commit edbcf6c

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
- Adapt test cases to pytest-asyncio 1.0 compatibility https://github.com/python-backoff/backoff/pull/1 from @pastalian
99
- Include tests in source distribution https://github.com/python-backoff/backoff/pull/13
1010
- Added `logging.LoggerAdapter` to `_MaybeLogger` union https://github.com/python-backoff/backoff/pull/34 from @jcbertin
11+
- Add `exception` to the typing-only `Details` dictionary for cases when `on_exception` is used https://github.com/python-backoff/backoff/pull/35
1112

1213
### Packaging
1314

backoff/_typing.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ class _Details(TypedDict):
2727
class Details(_Details, total=False):
2828
wait: float # present in the on_backoff handler case for either decorator
2929
value: Any # present in the on_predicate decorator case
30+
exception: Exception # present in the on_exception decorator case
3031

3132

3233
T = TypeVar("T")

0 commit comments

Comments
 (0)