-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add tenacity to sigup and SignUpError exception
- Loading branch information
Showing
5 changed files
with
25 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
import httpx | ||
from tenacity import retry | ||
from tenacity import retry_if_exception_type | ||
from tenacity import stop_after_attempt | ||
|
||
retry_on_read_timeout = retry( | ||
stop=stop_after_attempt(5), | ||
retry=retry_if_exception_type(httpx.ReadTimeout), | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,7 @@ build-backend = "setuptools.build_meta" | |
[project] | ||
name = "league-client" | ||
version = "2.1.5" | ||
dependencies = ["httpx"] | ||
dependencies = ["httpx", "tenacity"] | ||
requires-python = ">=3" | ||
authors = [{ name = "Pradish Bijukchhe", email = "[email protected]" }] | ||
description = "league-client is a python package to communicate with riot servers" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
httpx | ||
tenacity |