From 42bc6926ae7223044912e2fac372095573034fa2 Mon Sep 17 00:00:00 2001 From: chengxi Date: Sun, 7 Sep 2025 14:32:28 +0800 Subject: [PATCH 1/3] fix not found comfyui_to_python_utils --- comfyui_to_python.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/comfyui_to_python.py b/comfyui_to_python.py index ec9566e..d654069 100644 --- a/comfyui_to_python.py +++ b/comfyui_to_python.py @@ -11,7 +11,8 @@ from argparse import ArgumentParser import black - +# Add current directory to Python path +sys.path.insert(0, os.path.dirname(os.path.abspath(__file__))) from comfyui_to_python_utils import ( import_custom_nodes, find_path, From 76bc1c343e3cd0400fe0213bb9c544db7565fc96 Mon Sep 17 00:00:00 2001 From: chengxi Date: Sun, 7 Sep 2025 14:33:27 +0800 Subject: [PATCH 2/3] Fix conflict between comfy/utils.py and utils --- comfyui_to_python_utils.py | 1 + 1 file changed, 1 insertion(+) diff --git a/comfyui_to_python_utils.py b/comfyui_to_python_utils.py index 12b3be2..cff4393 100644 --- a/comfyui_to_python_utils.py +++ b/comfyui_to_python_utils.py @@ -12,6 +12,7 @@ def import_custom_nodes() -> None: import asyncio import execution from nodes import init_extra_nodes + sys.path.insert(0, find_path("ComfyUI")) import server # Creating a new event loop and setting it as the default loop From b215c83b763c1673d374e54361e6882f08d0eb7f Mon Sep 17 00:00:00 2001 From: chengxi Date: Sun, 7 Sep 2025 14:33:48 +0800 Subject: [PATCH 3/3] fix not await for load extra nodes --- comfyui_to_python_utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/comfyui_to_python_utils.py b/comfyui_to_python_utils.py index cff4393..0aefa4c 100644 --- a/comfyui_to_python_utils.py +++ b/comfyui_to_python_utils.py @@ -24,7 +24,7 @@ def import_custom_nodes() -> None: execution.PromptQueue(server_instance) # Initializing custom nodes - init_extra_nodes() + asyncio.run(init_extra_nodes()) def find_path(name: str, path: str = None) -> str: