parent
b6f97ee924
commit
70ae12eb77
@ -29,7 +29,7 @@ from pyrogram import __copyright__, __license__, __version__
|
||||
from pyrogram import raw
|
||||
from pyrogram.connection import Connection
|
||||
from pyrogram.crypto import mtproto
|
||||
from pyrogram.errors import RPCError, InternalServerError, AuthKeyDuplicated, FloodWait
|
||||
from pyrogram.errors import RPCError, InternalServerError, AuthKeyDuplicated, FloodWait, ServiceUnavailable
|
||||
from pyrogram.raw.all import layer
|
||||
from pyrogram.raw.core import TLObject, MsgContainer, Int, FutureSalt, FutureSalts
|
||||
from .internals import MsgId, MsgFactory
|
||||
@ -432,7 +432,7 @@ class Session:
|
||||
log.warning(f'[{self.client.session_name}] Sleeping for {amount}s (required by "{query}")')
|
||||
|
||||
await asyncio.sleep(amount)
|
||||
except (OSError, TimeoutError, InternalServerError) as e:
|
||||
except (OSError, TimeoutError, InternalServerError, ServiceUnavailable) as e:
|
||||
if retries == 0:
|
||||
raise e from None
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user