From 8a9e5d56cb44de5fa5b4cec92b4a368e5fab3d64 Mon Sep 17 00:00:00 2001 From: Austin Mroz Date: Thu, 17 Oct 2024 14:57:44 -0500 Subject: [PATCH] Remove errant on_prompt handler The orchestration code included functionality to track when execution had completed which is not useful outside of orchestration. As the other references to completion had been removed, this code was causing exceptions during execution. --- pyproject.toml | 2 +- workflowcheckpointing.py | 7 ------- 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index b8f7bec..243b49f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,7 @@ [project] name = "comfyui-workflowcheckpointing" description = "Automatically creates checkpoints during workflow execution. If If an workflow is canceled or ComfyUI crashes mid-execution, then these checkpoints are used when the workflow is re-queued to resume execution with minimal progress loss." -version = "1.1.0" +version = "1.1.1" license = { file = "LICENSE" } [project.urls] diff --git a/workflowcheckpointing.py b/workflowcheckpointing.py index 1f1309a..0530cdf 100644 --- a/workflowcheckpointing.py +++ b/workflowcheckpointing.py @@ -325,13 +325,6 @@ async def fetch_remote_files(remote_files, uid=None): if len(fetches) > 0: await asyncio.gather(*fetches) -completion_futures = {} -def add_future(json_data): - index = max(completion_futures.keys()) - json_data['extra_data']['completion_future'] = index - return json_data -server.PromptServer.instance.add_on_prompt_handler(add_future) - prompt_route = next(filter(lambda x: x.path == '/prompt' and x.method == 'POST', server.PromptServer.instance.routes)) original_post_prompt = prompt_route.handler