Skip to content

Frontend is not loading when installing packages as symlinks #9253

@Trojaner

Description

@Trojaner

Custom Node Testing

Expected Behavior

ComfyUI frontend should load and display stuff, even when web assets are behind symlinks

Actual Behavior

ComfyUI doesn't load, all static assets return 404

Image Image Image

Steps to Reproduce

  1. Clone ComfyUI (and install uv if its not available)
  2. Create venv: uv venv .venv
  3. Activate venv: source .venv/bin/activate
  4. Install packages as symlinks: uv pip install --link-mode=symlink -r requirements.txt (you can also use export UV_LINK_MODE=symlink instead of --link-mode=symlink)
  5. Confirm assets are symlinked by running ls -lah \<venv>/lib/python3.X/site-packages/comfyui_frontend_package/static/assets
    You should see assets as symlinks like this:
Image
  1. Start ComfyUI and notice how nothing loads when opening it in the browser

Debug Logs

The logs do not show any errors or warnings.

Other

uv's link-mode with hardlink/symlink is a very useful features to deduplicate storage usage across venvs on the same machine using the same libraries. This is especially useful for anything that uses ML related libraries like torch, as they tend to duplicate a lot of space.

However, ComfyUI does not seem to support this as it does not seem to follow symlinks when resolving assets from e.g. <venv>/lib/python3.X/site-packages/comfyui-frontend-package/static

Metadata

Metadata

Assignees

No one assigned

    Labels

    FeatureA new feature to add to ComfyUI.bug-cop:can-ignoreThe issue should be ignored by a bug cop, but doesn't necessarily need to be closed.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions