[patch] 优化DY日志结构 降低冗余代码

This commit is contained in:
2025-10-22 11:53:30 +08:00
parent a7864a05ee
commit 286d7916e9
3 changed files with 46 additions and 99 deletions

View File

@@ -433,6 +433,12 @@ class BackendClient:
self._send_to_backend(status_message),
self.loop
)
#
# # 🔥 等待发送完成(可选,避免警告)
# try:
# future.result(timeout=2) # 最多等待2秒
# except Exception as send_error:
# self._log(f"发送状态通知异常: {send_error}", "DEBUG")
status_text = "连接" if connected else "断开"
self._log(f"已通知后端GUI客户端{status_text}", "DEBUG")