Documenting macOS setup with tauri and ComfyUI

Author: metamasCreated Jul 30, 2023Updated Jan 1, 2024

Describe the bug When my tauri app window is launched, the "Welcome to StableStudio" seems to be stuck on the "Downloading ComfyUI..." loader for way too long. I inspected the downloader portion of the App file and then followed the download link to find that the .zip being downloaded is 2.6 GB.

https://github.com/Stability-AI/StableStudio/blob/f3b7d2048edc46992476a137019831bce6d5301e/packages/stablestudio-ui/src/App/index.tsx#L151-L158

Why so large? Are checkpoints being included in that .zip file?

This pain is particularly interesting to me right now because I'm currently on quite a slow connection.

Steps to reproduce I followed the setup instructions for the tauri branch. Then, whether I launch via cargo tauri dev or with packages/stablestudio-ui/src-tauri/target/release/StableStudio, the loading screen (mentioned above) moves at a snail's pace and always seems to get stuck at about 30% on the progress bar.

I still have not waited for it complete before losing patience and discontinuing the process. I tried multiple times, waiting ~1hr before realizing the progress bar didn't seem to be making anymore progress.

Expected behavior Even with my current slow connection, I expect a faster download. But I'm also concerned by the size of the .zip being downloaded. While I was waiting for StableStudio to "Downloading ComfyUI...", I was able to download and setup a standalone ComfyUI installation, so I'm confused about why it's taking StableStudio so much time/space to do the same. Seems like something inefficient and/or unnecessary may be happening.

Further notes I see the detect/download flow for ComfyUI, so I'm currently just looking into if there's a not-too-hacky way for me to set the comfyui_location setting to the directory where I already have working copy of ComfyUI.

https://github.com/Stability-AI/StableStudio/blob/f3b7d2048edc46992476a137019831bce6d5301e/packages/stablestudio-ui/src/App/index.tsx#L121-L123

If I trace comfyui_location to some nicely abstracted configs file/object, that will be great. Otherwise, I'll just edit references to comfyui_location with the path to my standalone copy of ComfyUI. If that works well, it might be worth providing an clear way for setting up a dev environment that uses an already installed ComfyUI, rather than downloading whatever is in ComfyUI_windows_portable.zip.

Also, I did notice an error in the Tauri web view inspector, when I looked at its console during one of the instances when the "Downloading ComfyUI..." progress bar seemed to get stuck. Sorry, I didn't copy it down. So, in any case, I'll look into that after I try my experiment above.

Smartphone (please complete the following information):

  • macOS Ventura
  • cargo 1.70
  • tauri-cli 1.4.0

Source: Stability-AI/StableStudio