Skip to content

Commit b5ddc48

Browse files
committed
fix(runtime): comfyui package breaking changes (#33)
1 parent 6ee4dd9 commit b5ddc48

File tree

3 files changed

+10
-3
lines changed

3 files changed

+10
-3
lines changed

README.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,12 @@ Install/update ComfyScript:
7373
python -m pip install -U "comfy-script[default]"
7474
```
7575

76-
(`[default]` is necessary to install common dependencies. See [`pyproject.toml`](pyproject.toml) for other options. If no option is specified, `comfy-script` will be installed without any dependencies.)
76+
`[default]` is necessary to install common dependencies. See [`pyproject.toml`](pyproject.toml) for other options. If no option is specified, `comfy-script` will be installed without any dependencies.
77+
78+
If there are problems with the latest ComfyUI package, one can use the last tested version:
79+
```
80+
python -m pip install --no-build-isolation git+https://github.com/hiddenswitch/ComfyUI.git@e49c662c7f026f05a5e082d48b629e2b977c0441
81+
```
7782

7883
### Other ways
7984
ComfyScript can also be used without installed ComfyUI. See [only ComfyScript package](docs/README.md#only-comfyscript-package) for details. And see [uninstallation](docs/README.md#uninstallation) for how to uninstall.

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "comfy-script"
3-
version = "0.4.4"
3+
version = "0.4.5"
44
description = "A Python front end and library for ComfyUI"
55
readme = "README.md"
66
# ComfyUI: >=3.8

src/comfy_script/runtime/__init__.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,9 @@ def setup_comfyui_polyfills(main_locals: dict = None):
232232

233233
import comfy.nodes.common
234234
nodes = types.ModuleType('nodes')
235-
exported_nodes = comfy.cmd.server.nodes
235+
exported_nodes = getattr(server, 'nodes', None)
236+
if exported_nodes is None:
237+
exported_nodes = comfy.cmd.server.nodes
236238
setattr(nodes, 'NODE_CLASS_MAPPINGS', exported_nodes.NODE_CLASS_MAPPINGS)
237239
setattr(nodes, 'NODE_DISPLAY_NAME_MAPPINGS', exported_nodes.NODE_DISPLAY_NAME_MAPPINGS)
238240
setattr(nodes, 'EXTENSION_WEB_DIRS', exported_nodes.EXTENSION_WEB_DIRS)

0 commit comments

Comments
 (0)