{"record":{"id":"cf0284f0bd23e62c","repo":"OpenBMB/ChatDev","slug":"failed-to-start-workflow-exc","errorCode":null,"errorMessage":"Failed to start workflow: {exc}","messagePattern":"Failed to start workflow: (.+?)","errorType":"exception","errorClass":"WorkflowExecutionError","httpStatus":null,"severity":"error","filePath":"server/routes/execute.py","lineNumber":53,"sourceCode":"        logger.info(\n            \"Workflow execution started\",\n            log_type=LogType.WORKFLOW,\n            session_id=request.session_id,\n            yaml_file=request.yaml_file,\n            task_prompt_length=len(request.task_prompt or \"\"),\n        )\n\n        return {\n            \"status\": \"started\",\n            \"session_id\": request.session_id,\n            \"message\": \"Workflow execution started\",\n        }\n    except ValidationError as exc:\n        raise HTTPException(status_code=400, detail=str(exc))\n    except Exception as exc:\n        logger = get_server_logger()\n        logger.log_exception(exc, \"Failed to start workflow execution\")\n        raise WorkflowExecutionError(f\"Failed to start workflow: {exc}\")\n","sourceCodeStart":35,"sourceCodeEnd":54,"githubUrl":"https://github.com/OpenBMB/ChatDev/blob/4fb2db0ea90375ce1059f44fe03ffbd191a7a169/server/routes/execute.py#L35-L54","documentation":"A non-ValidationError exception escaped while starting the workflow (e.g. inside asyncio.create_task setup or workflow_run_service.start_workflow). It is logged via the server logger and re-raised as WorkflowExecutionError with the original exception text.","triggerScenarios":"POST execute where start_workflow throws an unexpected error: missing config file, IO errors reading the YAML, or internal state problems in the workflow run service.","commonSituations":"Workflow YAML referencing missing files or tools; race conditions creating the background task; service dependencies (queues, stores) not initialized.","solutions":["Check the server log entry 'Failed to start workflow execution' for the original traceback and fix that root cause","Verify the YAML file path and workflow definition are valid","Ensure the session is connected and services initialized before starting","If it's an environment issue, restart the server after fixing configuration"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":"# pre-flight: confirm yaml_file and session connection\nassert manager_ready(session_id) and yaml_exists(request.yaml_file)","typeGuard":null,"tryCatchPattern":"try:\n    client.execute_workflow(req)\nexcept WorkflowExecutionError as e:\n    log_server_traceback()  # match via server log 'Failed to start workflow execution'\n    if 'No such file' in str(e): fix_yaml_path(req)","preventionTips":["Always inspect the server log for the original exception","Pre-validate workflow file paths before starting"],"tags":["workflow","http-500","internal-error"],"backgroundTag":"workflow-start-failed","analyzedSha":"4fb2db0ea90375ce1059f44fe03ffbd191a7a169","analyzedAt":"2026-08-27T14:35:29.622Z","schemaVersion":2},"datasetVersion":"2026-08-27T19:17:21.184Z"}