mirror of
https://github.com/PaiGramTeam/PaiGram.git
synced 2024-11-16 12:51:35 +00:00
🐛 Fix sign always raise TimeoutException
This commit is contained in:
parent
a33664882a
commit
5741e05f35
@ -177,6 +177,11 @@ class SignSystem(Plugin):
|
||||
try:
|
||||
await self.sign_with_recognize(client)
|
||||
break
|
||||
except TimeoutException as e:
|
||||
if ret == retry - 1:
|
||||
raise e
|
||||
await asyncio.sleep(random.randint(0, 3)) # nosec
|
||||
continue
|
||||
except NeedChallenge as e:
|
||||
if ret == retry - 1:
|
||||
# 重试次数用完,抛出异常
|
||||
|
Loading…
Reference in New Issue
Block a user