app/api/agent.py
@@ -143,14 +143,14 @@ elif 'report_name' in message_json: message = message_json['report_name'] except json.JSONDecodeError: except Exception as e: pass # 非 JSON 字符串,继续使用原始 message if session.get('files') and isinstance(session.get('files'), str): try: files = json.loads(session.get('files')) process_files(files, agent_id) except json.JSONDecodeError: except Exception as e: pass # 非 JSON 字符串,继续使用原始 message # 检查 message 是否为 None