update:修改python部分的“动态配置更新”的验证逻辑

This commit is contained in:
CGD
2025-04-30 18:11:46 +08:00
parent 4f829017ed
commit 1719244015
2 changed files with 16 additions and 11 deletions
-11
View File
@@ -222,19 +222,8 @@ class ConnectionHandler:
async def handle_config_update(self, message):
"""处理配置更新请求"""
content = message.get("content", {})
secret = content.pop("secret", None)
new_config = content
# 密钥验证
if secret != "43c716ae-37c4-49ba-84ab-2f0fbfcd7115":
self.logger.bind(tag=TAG).warning("配置更新请求的密钥不正确")
await self.websocket.send(json.dumps({
"type": "config_update_response",
"status": "error",
"message": "密钥不正确"
}))
return
# 遍历所有支持的配置模块
updated_modules = []
for config_model in ["tts", "llm", "vad", "asr", "memory", "intent"]: