Skip to content

[Bug]: Couldn't Install Clip #17201

@ZurokSlayer7X9

Description

@ZurokSlayer7X9

Checklist

  • The issue exists after disabling all extensions
  • The issue exists on a clean installation of webui
  • The issue is caused by an extension, but I believe it is caused by a bug in the webui
  • The issue exists in the current version of the webui
  • The issue has not been reported before recently
  • The issue has been reported before but has not been fixed yet

What happened?

I used the NVidia Automatic for Windows method with the sd.webui.zip.
When attempting to set up using the "run.bat" file, it eventually gets to the point where it attempts to install "clip". After that it will give me a "Press and key to continue..." which will close the Command Window and nothing else will happen.

I've seen others bring this issue up before, however their error codes are different than mine. I'm not very well versed in python to know exactly what is going on here. I've seen some solutions mention running a script in the "venv" folder, but I don't even have that, just a "tmp" folder.

I have done two clean installs, as well installing in fresh locations, however the same issue arises. I also ran the "update.bat" before running "run.bat".

Steps to reproduce the problem

  1. Double click "run.bat"
  2. Get error saying it cannot install clip.

What should have happened?

Install clip and open the WebUI I guess.

What browsers do you use to access the UI ?

Brave

Sysinfo

I cannot even get to the WebUI.

Console logs

Python 3.10.6 (tags/v3.10.6:9c7b4bd, Aug 1 2022, 21:53:49) [MSC v.1932 64 bit (AMD64)]
Version: v1.10.1
Commit hash:
Installing clip
Traceback (most recent call last):
File "M:\AI\Stable Diffusion\sd.webui\webui\launch.py", line 48, in
main()
File "M:\AI\Stable Diffusion\sd.webui\webui\launch.py", line 39, in main
prepare_environment()
File "M:\AI\Stable Diffusion\sd.webui\webui\modules\launch_utils.py", line 394, in prepare_environment
run_pip(f"install {clip_package}", "clip")
File "M:\AI\Stable Diffusion\sd.webui\webui\modules\launch_utils.py", line 144, in run_pip
return run(f'"{python}" -m pip {command} --prefer-binary{index_url_line}', desc=f"Installing {desc}", errdesc=f"Couldn't install {desc}", live=live)
File "M:\AI\Stable Diffusion\sd.webui\webui\modules\launch_utils.py", line 116, in run
raise RuntimeError("\n".join(error_bits))
RuntimeError: Couldn't install clip.
Command: "M:\AI\Stable Diffusion\sd.webui\system\python\python.exe" -m pip install https://github.com/openai/CLIP/archive/d50d76daa670286dd6cacf3bcd80b5e4823fc8e1.zip --prefer-binary
Error code: 2
stdout: Collecting https://github.com/openai/CLIP/archive/d50d76daa670286dd6cacf3bcd80b5e4823fc8e1.zip
Using cached https://github.com/openai/CLIP/archive/d50d76daa670286dd6cacf3bcd80b5e4823fc8e1.zip (4.3 MB)
Installing build dependencies: started
Installing build dependencies: finished with status 'done'
Getting requirements to build wheel: started
Getting requirements to build wheel: finished with status 'done'

stderr: ERROR: Exception:
Traceback (most recent call last):
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\cli\base_command.py", line 107, in _run_wrapper
status = _inner_run()
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\cli\base_command.py", line 98, in _inner_run
return self.run(options, args)
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\cli\req_command.py", line 85, in wrapper
return func(self, options, args)
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\commands\install.py", line 388, in run
requirement_set = resolver.resolve(
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\resolution\resolvelib\resolver.py", line 79, in resolve
collected = self.factory.collect_root_requirements(root_reqs)
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\resolution\resolvelib\factory.py", line 538, in collect_root_requirements
reqs = list(
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\resolution\resolvelib\factory.py", line 494, in _make_requirements_from_install_req
cand = self._make_base_candidate_from_link(
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\resolution\resolvelib\factory.py", line 226, in _make_base_candidate_from_link
self._link_candidate_cache[link] = LinkCandidate(
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\resolution\resolvelib\candidates.py", line 318, in init
super().init(
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\resolution\resolvelib\candidates.py", line 161, in init
self.dist = self._prepare()
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\resolution\resolvelib\candidates.py", line 238, in _prepare
dist = self._prepare_distribution()
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\resolution\resolvelib\candidates.py", line 329, in _prepare_distribution
return preparer.prepare_linked_requirement(self._ireq, parallel_builds=True)
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\operations\prepare.py", line 543, in prepare_linked_requirement
return self._prepare_linked_requirement(req, parallel_builds)
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\operations\prepare.py", line 658, in _prepare_linked_requirement
dist = _get_prepared_distribution(
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\operations\prepare.py", line 77, in _get_prepared_distribution
abstract_dist.prepare_distribution_metadata(
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\distributions\sdist.py", line 55, in prepare_distribution_metadata
self._install_build_reqs(build_env_installer)
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\distributions\sdist.py", line 132, in _install_build_reqs
build_reqs = self._get_build_requires_wheel()
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\distributions\sdist.py", line 107, in _get_build_requires_wheel
return backend.get_requires_for_build_wheel()
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_internal\utils\misc.py", line 694, in get_requires_for_build_wheel
return super().get_requires_for_build_wheel(config_settings=cs)
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_vendor\pyproject_hooks_impl.py", line 196, in get_requires_for_build_wheel
return self._call_hook(
File "M:\AI\Stable Diffusion\sd.webui\system\python\lib\site-packages\pip_vendor\pyproject_hooks_impl.py", line 402, in _call_hook
raise BackendUnavailable(
pip._vendor.pyproject_hooks._impl.BackendUnavailable: Cannot import 'setuptools.build_meta'

Additional information

I have a newer version of Python, but am using pyenv-win to downgrade from 3.12.4 to 3.10.6. Both the Command Prompt from run.bat as well as PowerShell recognize 3.10.6 as the version.

Using an RTX 3090 if that makes any difference.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug-reportReport of a bug, yet to be confirmed

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions