mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2024-11-23 01:46:35 +03:00
Except TypeNotFoundError on ._invoke()
This commit is contained in:
parent
6c73538bd4
commit
db698858e0
|
@ -501,6 +501,15 @@ class TelegramBareClient:
|
|||
__log__.error('Authorization key seems broken and was invalid!')
|
||||
self.session.auth_key = None
|
||||
|
||||
except TypeNotFoundError as e:
|
||||
# Only occurs when we call receive. May happen when
|
||||
# we need to reconnect to another DC on login and
|
||||
# Telegram somehow sends old objects (like configOld)
|
||||
self._first_request = True
|
||||
__log__.warning('Read unknown TLObject code ({}). '
|
||||
'Setting again first_request flag.'
|
||||
.format(hex(e.invalid_constructor_id)))
|
||||
|
||||
except TimeoutError:
|
||||
__log__.warning('Invoking timed out') # We will just retry
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user