修复测试用例流结束判断

This commit is contained in:
yangdx
2025-01-15 21:26:20 +08:00
parent af9ac188f0
commit 6d44178f63
2 changed files with 13 additions and 13 deletions

View File

@@ -70,7 +70,7 @@ def test_stream_chat():
for event in client.events():
try:
data = json.loads(event.data)
if data.get("done", False): # 如果是完成标记
if data.get("done", True): # 如果是完成标记
if "total_duration" in data: # 最终的性能统计消息
print("\n=== 性能统计 ===")
print(json.dumps(data, ensure_ascii=False, indent=2))