From 709f84f63c15a8282e70345f3ec82fd7434d6c7b Mon Sep 17 00:00:00 2001 From: Brian Gebel Date: Tue, 26 May 2026 21:48:44 -0700 Subject: [PATCH] fix(complete): pre-install Impact/Subpack/Inspire deps to avoid load race MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ComfyUI loads custom nodes synchronously during startup, but ComfyUI-Manager installs their pip dependencies *after* node loading. On every fresh pod boot in K8s (where /app/.venv is ephemeral), this race causes: - comfyui-impact-pack → ModuleNotFoundError: segment_anything - comfyui-impact-subpack → ModuleNotFoundError: dill - comfyui-inspire-pack → ModuleNotFoundError: webcolors Manager later installs each successfully and prints "After restarting ComfyUI, please refresh the browser." — but K8s never restarts the pod, so the nodes stay broken until manual intervention. Bakes the three missing deps into extra-requirements.txt so they're present in /app/.venv before ComfyUI starts loading nodes. The pack sections in the file are reorganised: - "Impact Pack dependencies" → "Impact Pack + Subpack dependencies" (piexif, ultralytics, segment-anything, dill) - New "Inspire Pack dependencies" group (webcolors) ultralytics was already baked in; this just completes the set. Co-Authored-By: Claude Opus 4.7 (1M context) --- services/comfy/complete/extra-requirements.txt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/services/comfy/complete/extra-requirements.txt b/services/comfy/complete/extra-requirements.txt index 9a7d1cb..b2f6d20 100644 --- a/services/comfy/complete/extra-requirements.txt +++ b/services/comfy/complete/extra-requirements.txt @@ -14,9 +14,14 @@ matplotlib>=3.10 facexlib>=0.3 insightface>=0.7 -# ComfyUI Impact Pack dependencies +# ComfyUI Impact Pack + Subpack dependencies piexif>=1.1 ultralytics>=8.3 +segment-anything>=1.0 +dill>=0.3 + +# ComfyUI Inspire Pack dependencies +webcolors>=24.0 # RMBG and AILab Segmentation timm>=1.0