Skip to content

Commit

Permalink
Allow None for jitter kwarg (typing)
Browse files Browse the repository at this point in the history
  • Loading branch information
bgreen-litl committed Apr 27, 2022
1 parent f64df27 commit 060d641
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions backoff/_decorator.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def on_predicate(wait_gen: _WaitGenerator,
*,
max_tries: Optional[_MaybeCallable[int]] = None,
max_time: Optional[_MaybeCallable[float]] = None,
jitter: _Jitterer = full_jitter,
jitter: Union[_Jitterer, None] = full_jitter,
on_success: Union[_Handler, Iterable[_Handler]] = None,
on_backoff: Union[_Handler, Iterable[_Handler]] = None,
on_giveup: Union[_Handler, Iterable[_Handler]] = None,
Expand Down Expand Up @@ -125,7 +125,7 @@ def on_exception(wait_gen: _WaitGenerator,
*,
max_tries: Optional[_MaybeCallable[int]] = None,
max_time: Optional[_MaybeCallable[float]] = None,
jitter: _Jitterer = full_jitter,
jitter: Union[_Jitterer, None] = full_jitter,
giveup: _Predicate[Exception] = lambda e: False,
on_success: Union[_Handler, Iterable[_Handler]] = None,
on_backoff: Union[_Handler, Iterable[_Handler]] = None,
Expand Down

0 comments on commit 060d641

Please sign in to comment.