如果失败了,则不进行登录动作。退出二次登录尝试,防止死循环尝试

This commit is contained in:
liuwei
2025-08-20 14:18:19 +08:00
parent 4a55bf9493
commit 4064c90648
2 changed files with 4 additions and 1 deletions

View File

@@ -643,6 +643,8 @@ class Robot:
self.LOG.info(f"ipad_wechat stopped change running:{self.ipad_running}") self.LOG.info(f"ipad_wechat stopped change running:{self.ipad_running}")
else: else:
self.LOG.error(f"定时二次登录失败!") self.LOG.error(f"定时二次登录失败!")
self.ipad_running = False
except Exception as e: except Exception as e:
self.LOG.error(f"login_twice_auto_auth error: {e}") self.LOG.error(f"login_twice_auto_auth error: {e}")

View File

@@ -226,7 +226,8 @@ class LoginMixin(WechatAPIClientBase):
if json_resp.get("Success"): if json_resp.get("Success"):
return True return True
else: else:
self.error_handler(json_resp) logger.error("Twice Auto Auth Failed")
return False
@staticmethod @staticmethod
def create_device_name() -> str: def create_device_name() -> str: