Add experimental support for async sessions (#4667)

There no plans for this to ever be non-experimental in v1.
This commit is contained in:
Humberto Gontijo
2025-07-28 12:03:31 -03:00
committed by GitHub
parent 45a546a675
commit d80898ecc5
7 changed files with 75 additions and 46 deletions

View File

@@ -302,7 +302,7 @@ class MTProtoSender:
# notify whenever we change it. This is crucial when we
# switch to different data centers.
if self._auth_key_callback:
self._auth_key_callback(self.auth_key)
await self._auth_key_callback(self.auth_key)
self._log.debug('auth_key generation success!')
return True