Fix: Loop in cloud_exit when task queue empty

This commit is contained in:
LmeSzinc 2024-05-30 22:03:41 +08:00
parent 58ba02fe29
commit c729421bd2

View File

@ -422,6 +422,10 @@ class LoginAndroidCloud(ModuleBase):
out: XPath.START_GAME
"""
logger.hr('Cloud exit')
if not self.device.app_is_running():
logger.info('App is not running, no need to exit')
return
while 1:
if skip_first:
skip_first = False
@ -475,6 +479,8 @@ class LoginAndroidCloud(ModuleBase):
if current != prev:
break
logger.info('Cloud exited')
def cloud_keep_alive(self):
"""
Randomly do something to prevent being kicked