Skip to content

Change of comfy.types to comfy.comfy_types #44

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
formulake opened this issue Sep 13, 2024 · 3 comments
Closed

Change of comfy.types to comfy.comfy_types #44

formulake opened this issue Sep 13, 2024 · 3 comments

Comments

@formulake
Copy link

formulake commented Sep 13, 2024

ComfyUI's latest update broke the nodes because of a filename change that impacts line 31 of model_patcher.py. I've made the change manually as of now, to line 31 from:

from comfy.types import UnetWrapperFunction

to

from comfy.comfy_types import UnetWrapperFunction

@Piscabo
Copy link

Piscabo commented Sep 13, 2024

I have the same issue:
0.2 seconds (IMPORT FAILED): H:\ComfyUI\custom_nodes\Fooocus_Nodes

File "H:\ComfyUI\custom_nodes\Fooocus_Nodes\py\modules\core.py", line 8, in
import ldm_patched.modules.model_patcher
File "H:\ComfyUI\custom_nodes\Fooocus_Nodes\py\ldm_patched\modules\model_patcher.py", line 31, in
from comfy.types import UnetWrapperFunction
ModuleNotFoundError: No module named 'comfy.types'

@formulake
Copy link
Author

Till the nodes is updated, you can open the file located at H:\ComfyUI\custom_nodes\Fooocus_Nodes\py\ldm_patched\modules\model_patcher.py in a text editor like notepad++ and change line 31. It currently reads:
from comfy.types import UnetWrapperFunction

change it to:
from comfy.comfy_types import UnetWrapperFunction

It'll run fine after that.

Seedsa added a commit that referenced this issue Sep 14, 2024
@mrhan1993
Copy link

I think try catch is better, Otherwise, the older version will receive another import error, 😞

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants