Comfy-Org / Comfy-Org/ComfyUI

ComfyUI first-generation corruption occurs only on first image generation after launch.

Open
#13,587 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
133k
Forks
15.7k
Avg merge
1d 6h
Merged PRs (30d)
155

Description

System:

Windows 11
RTX 3070 Ti Laptop GPU (8GB)
ComfyUI 0.17.2 rev 4905
Torch 2.9.1+cu130

Behaviour:

First generation after launch is corrupted
Second generation with identical settings is clean

Testing:

--cuda-malloc alone: does not fix
--disable-cuda-malloc alone: does not fix
--cuda-malloc --disable-cuda-malloc together: fixes the issue consistently

Important:

Order appears relevant
Working launch command:

.\python_embeded\python.exe -s ComfyUI\main.py --disable-api-nodes --windows-standalone-build --cuda-malloc --disable-cuda-malloc

This suggests allocator initialisation differs from final allocator selection, and both flags together change first-run startup behaviour in a way neither flag alone does.

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the first-generation corruption with the reported Windows command and ComfyUI\main.py entry point, comparing runs with each allocator flag alone and both together. Trace where allocator initialization and final selection occur during startup; done means the first generation is clean without requiring both conflicting flags.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, pytorch
Domain
ai, backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.