Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

手动安装docopt失败 #114

Open
aqidesign opened this issue May 31, 2024 · 3 comments
Open

手动安装docopt失败 #114

aqidesign opened this issue May 31, 2024 · 3 comments

Comments

@aqidesign
Copy link

看了之前的issue,下载了docopt手动安装,但是也安装不了,请问是怎么回事呢?

安装提示如下:

D:\ComfyUI_windows_portable\python_embeded>pip install docopt-0.6.2-py2.py3-none-any.whl
Processing d:\comfyui_windows_portable\python_embeded\docopt-0.6.2-py2.py3-none-any.whl
ERROR: Wheel 'docopt' located at D:\ComfyUI_windows_portable\python_embeded\docopt-0.6.2-py2.py3-none-any.whl is invalid.

@aqidesign
Copy link
Author

https://github.com/GoogleCloudPlatform/gcloud-python-wheels/blob/master/wheelhouse/docopt-0.6.2-py2.py3-none-any.whl
使用上面的文件安装成功了

@52Hz-p
Copy link

52Hz-p commented Jun 1, 2024

https://github.com/GoogleCloudPlatform/gcloud-python-wheels/blob/master/wheelhouse/docopt-0.6.2-py2.py3-none-any.whl 使用上面的文件安装成功了

怎么安装这个文件,是打开cmd 然后导航到这个文件的地址,然后输入到H:\ComfyUI\CF\ComfyUI_windows_portable\python_embeded\python.exe -s -m pip install docopt-0.6.2-py2.py3-none-any.whl这里,但是安装后,还是不起作用,插件依旧无法载入

@blueraincoatli
Copy link

我也碰到相同问题——安装psd-tools时,碰到docopt依赖安装失败,这个被称为“依赖地狱”,后来手工下载了docopt的原代码,但仍旧安装不成功,说是setup.py文件中要导入__version__,但此时并未安装好docopt,因此拿不到这个版本号,导致安装失败。
后来我修改了setup.py的代码,终于安装成功,进而能够安装psd-tools,并且layerstyle节点终于可以正常载入了。
方法如下,如有相同问题的朋友可以参考:

  1. 先在 [https://pypi.org/project/docopt/] 手工下载docopt-0.6.2.tar,(download files)
  2. 在解压目录下编辑setup.py文件,
    将from docopt import __version__这句代码替换为
    try:
    from docopt import version
    except ImportError:
    version = '0.6.2'
  3. 用.....setup.py install这样的方式安装,我这里路径不在一起,所以前面还用set...定义了一个路径,具体手工安装这个setup.py,朋友们可以问任意一个大语言模型。
  4. 成功安装docopt之后,就可以正常 pip install psd-tools了,然后layerStyle节点就可以正常载入了。
    祝各位好运!

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

No branches or pull requests

3 participants