ComfyUI
ComfyUI copied to clipboard
LoadImage crashes ComfyUI when file does not exist
If a workflow is loaded, and it contains a LoadImage node that points to a file that does not exist, ComfyUI reports an error in the console and no image is generated. After which, ComfyUI will not generate any images. Even if the file for LoadImage is fixed to point to a file that does exist, ComfyUI will not generate any images, and no errors will be reported.
Steps to reproduce:
- Add a file named
test.pngin theinputdirectory. - Start ComfyUI.
- Load the default workflow.
- Add a LoadImage node and point it to
test.png. (It doesn't need to be connected to anything.) - Press Queue Prompt and wait for an image to generate.
- Rename
test.pngtotest.png.bak. - Press Queue Prompt.
- Note that an image is not generated and an error is displayed in the console.
- Rename
test.png.baktotest.png. - Press Queue Prompt.
- Note that an image is not generated and no error is sent to the console.
- Delete the LoadImage node.
- Press Queue Prompt.
- Note that an image is still not generated and no error is sent to the console.
It seems like ComfyUI should be able to recover from this issue, but it does not. It should also display an error in the web UI since the file does not exist.