Merge pull request #2938 from xinnan-tech/test_live2d

update:测试页面增加切换live2d模型、拍照识物功能
This commit is contained in:
wengzh
2026-02-05 17:00:11 +08:00
committed by GitHub
58 changed files with 21525 additions and 165 deletions
@@ -29,7 +29,15 @@ class VisionHandler(BaseHandler):
def _verify_auth_token(self, request) -> Tuple[bool, Optional[str]]:
"""验证认证token"""
# 测试模式:允许特定测试令牌或跳过验证
auth_header = request.headers.get("Authorization", "")
client_id = request.headers.get("Client-Id", "")
# 允许测试客户端跳过认证
if client_id == "web_test_client":
device_id = request.headers.get("Device-Id", "test_device")
return True, device_id
if not auth_header.startswith("Bearer "):
return False, None