From 7e86c203833ebf3591d8ac2f082ab306ebc4befa Mon Sep 17 00:00:00 2001 From: bennykok Date: Wed, 7 Feb 2024 23:50:00 +0800 Subject: [PATCH] fix(plugin): ensure the status of run is set to fail if the prompt validation failed --- custom_routes.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/custom_routes.py b/custom_routes.py index 873180f..9d54be7 100644 --- a/custom_routes.py +++ b/custom_routes.py @@ -118,6 +118,8 @@ async def comfy_deploy_run(request): "stack_trace": stack_trace } }) + # When there are critical errors, the prompt is actually not run + await update_run(prompt_id, Status.FAILED) return web.Response(status=500, reason=f"{error_type}: {e}, {stack_trace_short}") status = 200