mirror of
https://github.com/rangermix/TwitchDropsMiner.git
synced 2026-05-30 08:59:36 +00:00
Handle GQL service timeout
This commit is contained in:
@@ -1279,6 +1279,12 @@ class Twitch:
|
||||
continue
|
||||
gql_logger.debug(f"GQL Response: {response_json}")
|
||||
if "errors" in response_json and response_json["errors"]:
|
||||
if (
|
||||
"message" in response_json["errors"]
|
||||
and response_json["errors"]["message"] == "service timeout"
|
||||
):
|
||||
await asyncio.sleep(1)
|
||||
continue
|
||||
raise MinerException(f"GQL error: {response_json['errors']}")
|
||||
return response_json
|
||||
|
||||
|
||||
Reference in New Issue
Block a user