Small update to allow comfyui_to_python.py to run from any subdirectory inside of ComfyUI.

This commit is contained in:
pydn
2024-09-14 13:43:10 -05:00
parent d5b1896fec
commit aa5416634c
2 changed files with 2 additions and 4 deletions
+2 -2
View File
@@ -20,7 +20,7 @@ from comfyui_to_python_utils import (
get_value_at_index,
)
sys.path.append("../")
add_comfyui_directory_to_sys_path()
from nodes import NODE_CLASS_MAPPINGS
@@ -617,7 +617,7 @@ def main() -> None:
default=DEFAULT_QUEUE_SIZE,
)
pargs = parser.parse_args()
ComfyUItoPython(**vars(pargs))
run(**vars(pargs))
print("Done.")
-2
View File
@@ -2,8 +2,6 @@ import os
from typing import Sequence, Mapping, Any, Union
import sys
sys.path.append("../")
def import_custom_nodes() -> None:
"""Find all custom nodes in the custom_nodes folder and add those node objects to NODE_CLASS_MAPPINGS