ComfyUI-to-Python-Extension icon indicating copy to clipboard operation
ComfyUI-to-Python-Extension copied to clipboard

ModuleNotFoundError: No module named 'nodes'

Open ross-Hr opened this issue 10 months ago • 5 comments

When i run the comfyui(v0.3.13) in win11, i can not convert :

` python .\comfyui_to_python.py Traceback (most recent call last):

File "D:\code\comfyui\ins\custom_nodes\ComfyUI-to-Python-Extension\comfyui_to_python.py", line 24, in from nodes import NODE_CLASS_MAPPINGS

ModuleNotFoundError: No module named 'nodes'`

ross-Hr avatar Feb 06 '25 08:02 ross-Hr

Pls have you solved this problem

goofyandgoofy avatar Mar 06 '25 18:03 goofyandgoofy

having this issue too

DivineTimes avatar May 21 '25 17:05 DivineTimes

+1

vascobarbosa avatar Jul 16 '25 23:07 vascobarbosa

This issue occurs because the ComfyUI path is not included in the system's Python paths. To resolve it, you can manually add your ComfyUI directory path to the system paths. This can be done by modifying the path configuration in the following file: https://github.com/pydn/ComfyUI-to-Python-Extension/blob/1c0585fabed4d741636798583af10dd5ebb00305/comfyui_to_python_utils.py#L55

GreatenAnoymous avatar Aug 30 '25 09:08 GreatenAnoymous

It is recommended to use portable comfyui instead of desktop version, and then use my pr version, https://github.com/pydn/ComfyUI-to-Python-Extension/pull/133

xiaoxidashen avatar Sep 07 '25 06:09 xiaoxidashen