Skip to content

fix(launch): add --no-build-isolation to open_clip and requirements installs#17371

Open
lfl1337 wants to merge 1 commit intoAUTOMATIC1111:devfrom
lfl1337:fix/no-build-isolation-open-clip-requirements
Open

fix(launch): add --no-build-isolation to open_clip and requirements installs#17371
lfl1337 wants to merge 1 commit intoAUTOMATIC1111:devfrom
lfl1337:fix/no-build-isolation-open-clip-requirements

Conversation

@lfl1337
Copy link
Copy Markdown

@lfl1337 lfl1337 commented Apr 13, 2026

What was changed?

Added --no-build-isolation to the open_clip and requirements pip install calls in prepare_environment(), mirroring the existing flag already applied to clip.

Why?

Commit 76759a1 fixed CLIP installation failures (#17201, #17284, #17287) by adding --no-build-isolation to the clip install. The same flag was missing from two other install calls in the same block:

  • open_clip — installed from a GitHub ZIP (source distribution)
  • requirements_versions.txt — contains jsonmerge==1.8.0 (source distribution, no binary wheel)

With pip 26+, the isolated build environment fails to import setuptools.build_meta for source distributions:

BackendUnavailable: Cannot import 'setuptools.build_meta'
RuntimeError: Couldn't install open_clip.
RuntimeError: Couldn't install requirements.

This causes a complete startup failure on portable/embedded Python 3.10.6 environments (e.g. the sd.webui one-click package) after pip auto-updates to 26+.

Using --no-build-isolation lets pip use the already-installed setuptools==69.5.1 (pinned as line 1 of requirements_versions.txt) directly, avoiding the broken isolated build environment.

How to reproduce

  1. Use the sd.webui one-click portable package (embedded Python 3.10.6)
  2. Let pip update to 26+ (happens automatically via get-pip.py)
  3. Run run.bat — startup fails with BackendUnavailable: Cannot import 'setuptools.build_meta'

How to test

Run run.bat on a portable sd.webui installation with pip 26+ — startup completes successfully.

Checklist

…nstalls

Commit 76759a1 added --no-build-isolation to the clip install to fix
BackendUnavailable errors with pip 26+ on embedded/portable Python
environments, but the same flag was missing from open_clip and the
requirements installs.

open_clip (GitHub ZIP) and jsonmerge (in requirements_versions.txt) are
source distributions that pip must build. With pip 26+, the isolated
build environment fails to import setuptools.build_meta, causing:

  BackendUnavailable: Cannot import 'setuptools.build_meta'

Adding --no-build-isolation to these calls mirrors the existing fix
for clip and allows pip to use the already-installed setuptools
(69.5.1, pinned in requirements_versions.txt) directly.

Fixes startup failures on portable/embedded Python 3.10.6 installs
(e.g. sd.webui one-click package) with pip 26+.

Related: AUTOMATIC1111#17201 AUTOMATIC1111#17284 AUTOMATIC1111#17287

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant