in uamqp/client.py [0:0]
def auth_complete(self):
"""Whether the authentication handshake is complete during
connection initialization.
:rtype: bool
"""
timeout = False
auth_in_progress = False
if self._connection._cbs: # pylint: disable=protected-access
timeout, auth_in_progress = self._auth.handle_token()
if timeout is None and auth_in_progress is None:
_logger.debug("No work done.")
return False
if timeout:
raise compat.TimeoutException("Authorization timeout.")
if auth_in_progress:
self._connection.work()
return False
return True