We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How i can catch the exceptions for example if the summoner is not found and I want to catch it so I can return a custom message.
def test():
lol_manager = LolManager() puuid = "ovqw2cGBNvqhlGZV3u1lBWmROrfXVTnjjAfoOd5GN-e_YeTGnVossVzw84Z_GDHpvgDC_fVJ3FQACg1" server = "EUW" try: summoner = lol_manager.get_summoner_by_puuid(puuid=puuid, region=server) print("Summoner found:", summoner.account_id) except HTTPError as e: print("HTTP error:", e) except Exception as e: print("An unexpected error occurred:", e)
my settings
settings = { "RiotAPI": { "api_key": RIOT_API_KEY, "request_error_handling": { "404": {"strategy": "throw"}, "429": { "service": { "strategy": "exponential_backoff", "initial_backoff": 1.0, "backoff_factor": 2.0, "max_attempts": 4, }, "method": {"strategy": "retry_from_headers", "max_attempts": 5}, "application": { "strategy": "retry_from_headers", "max_attempts": 5, }, }, "500": { "strategy": "exponential_backoff", "initial_backoff": 1.0, "backoff_factor": 2.0, "max_attempts": 4, }, "503": { "strategy": "exponential_backoff", "initial_backoff": 1.0, "backoff_factor": 2.0, "max_attempts": 8, }, "timeout": {"strategy": "throw"}, "403": {"strategy": "throw"}, "504": { "strategy": "exponential_backoff", "initial_backoff": 1.0, "backoff_factor": 2.0, "max_attempts": 4, }, "502": { "strategy": "exponential_backoff", "initial_backoff": 1.0, "backoff_factor": 2.0, "max_attempts": 4, }, }, } } ```
The text was updated successfully, but these errors were encountered:
Hey, can you assign me this issue please !
Sorry, something went wrong.
No branches or pull requests
How i can catch the exceptions for example if the summoner is not found and I want to catch it so I can return a custom message.
def test():
my settings
The text was updated successfully, but these errors were encountered: