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

(IMPORT FAILED) error occured #99

Closed
lishrliu opened this issue Nov 29, 2024 · 8 comments
Closed

(IMPORT FAILED) error occured #99

lishrliu opened this issue Nov 29, 2024 · 8 comments

Comments

@lishrliu
Copy link

Preparing metadata (pyproject.toml): started
Preparing metadata (pyproject.toml): finished with status 'error'
error: subprocess-exited-with-error

× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [32 lines of output]
pyproject.toml: line 7: using '[tool.sip.metadata]' to specify the project metadata is deprecated and will be removed in SIP v7.0.0, use '[project]' instead
Traceback (most recent call last):
File "/Users/lishrliu/StableDiffusion/ComfyUI/venv/lib/python3.13/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in
main()

File "/Users/lishrliu/StableDiffusion/ComfyUI/venv/lib/python3.13/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
~~~~^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/lishrliu/StableDiffusion/ComfyUI/venv/lib/python3.13/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 152, in prepare_metadata_for_build_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-gwahmojv/overlay/lib/python3.13/site-packages/sipbuild/api.py", line 28, in build_wheel
project = AbstractProject.bootstrap('wheel',
arguments=_convert_config_settings(config_settings))
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-gwahmojv/overlay/lib/python3.13/site-packages/sipbuild/abstract_project.py", line 74, in bootstrap
project.setup(pyproject, tool, tool_description)
~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-gwahmojv/overlay/lib/python3.13/site-packages/sipbuild/project.py", line 608, in setup
self.apply_user_defaults(tool)
~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-install-adaci5n2/pyqt5_e94979b37cc644bbbda8fe355b6bb450/project.py", line 63, in apply_user_defaults
super().apply_user_defaults(tool)
~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-gwahmojv/overlay/lib/python3.13/site-packages/pyqtbuild/project.py", line 51, in apply_user_defaults
super().apply_user_defaults(tool)
~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-gwahmojv/overlay/lib/python3.13/site-packages/sipbuild/project.py", line 237, in apply_user_defaults
self.builder.apply_user_defaults(tool)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-gwahmojv/overlay/lib/python3.13/site-packages/pyqtbuild/builder.py", line 50, in apply_user_defaults
raise PyProjectOptionException('qmake',
"specify a working qmake or add it to PATH")
sipbuild.pyproject.PyProjectOptionException
[end of output]
  
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed


× Encountered error while generating package metadata.
╰─> See above for output.


note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
### [END] ComfyUI AlekPet Nodes ###
Traceback (most recent call last):
File "/Users/lishrliu/StableDiffusion/ComfyUI/nodes.py", line 2026, in load_custom_node
module_spec.loader.exec_module(module)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^
File "<frozen importlib._bootstrap_external>", line 1022, in exec_module
File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
File "/Users/lishrliu/StableDiffusion/ComfyUI/custom_nodes/ComfyUI_Custom_Nodes_AlekPet/__init__.py", line 275, in <module>
from .ArgosTranslateNode.argos_translate_node import (
...<2 lines>...
)
File "/Users/lishrliu/StableDiffusion/ComfyUI/custom_nodes/ComfyUI_Custom_Nodes_AlekPet/ArgosTranslateNode/argos_translate_node.py", line 4, in <module>
import argostranslate.package
ModuleNotFoundError: No module named 'argostranslate'


Cannot import /Users/lishrliu/StableDiffusion/ComfyUI/custom_nodes/ComfyUI_Custom_Nodes_AlekPet module for custom nodes: No module named 'argostranslate'


Import times for custom nodes:


5.8 seconds (IMPORT FAILED): /Users/lishrliu/StableDiffusion/ComfyUI/custom_nodes/ComfyUI_Custom_Nodes_AlekPet


WARNING: some comfy_extras/ nodes did not import correctly. This may be because they are missing some dependencies.


IMPORT FAILED: nodes_canny.py
IMPORT FAILED: nodes_morphology.py
@lishrliu lishrliu changed the title 导入失败 (IMPORT FAILED) error occured Nov 29, 2024
@AlekPet
Copy link
Owner

AlekPet commented Nov 29, 2024

Hi, I already answered a similar question #93 (comment)

@lishrliu
Copy link
Author

lishrliu commented Dec 1, 2024

(venv) ComfyUI % pip install argostranslate
Collecting argostranslate
Using cached argostranslate-1.9.6-py3-none-any.whl.metadata (10 kB)
INFO: pip is looking at multiple versions of argostranslate to determine which version is compatible with other requirements. This could take a while.
Using cached argostranslate-1.9.5-py3-none-any.whl.metadata (10 kB)
Using cached argostranslate-1.9.4-py3-none-any.whl.metadata (10 kB)
Using cached argostranslate-1.9.3-py3-none-any.whl.metadata (9.9 kB)
Using cached argostranslate-1.9.2-py3-none-any.whl.metadata (10.0 kB)
Using cached argostranslate-1.9.1-py3-none-any.whl.metadata (9.7 kB)
Using cached argostranslate-1.9.0-py3-none-any.whl.metadata (9.7 kB)
Using cached argostranslate-1.8.3-py3-none-any.whl.metadata (9.7 kB)
INFO: pip is still looking at multiple versions of argostranslate to determine which version is compatible with other requirements. This could take a while.
Using cached argostranslate-1.8.2-py3-none-any.whl.metadata (9.6 kB)
Using cached argostranslate-1.8.1-py3-none-any.whl.metadata (9.7 kB)
Using cached argostranslate-1.8.0-py3-none-any.whl.metadata (8.9 kB)
Using cached argostranslate-1.7.5-py3-none-any.whl.metadata (9.1 kB)
Using cached argostranslate-1.7.4-py3-none-any.whl.metadata (9.1 kB)
INFO: This is taking longer than usual. You might need to provide the dependency resolver with stricter constraints to reduce runtime. See https://pip.pypa.io/warnings/backtracking for guidance. If you want to abort this run, press Ctrl + C.
Using cached argostranslate-1.7.3-py3-none-any.whl.metadata (9.2 kB)
Using cached argostranslate-1.7.2-py3-none-any.whl.metadata (9.2 kB)
Using cached argostranslate-1.7.0-py3-none-any.whl.metadata (9.3 kB)
Using cached argostranslate-1.6.1-py3-none-any.whl.metadata (14 kB)
Using cached argostranslate-1.6.0-py3-none-any.whl.metadata (14 kB)
Using cached argostranslate-1.5.4-py3-none-any.whl.metadata (14 kB)
Collecting PyQt5==5.15.4 (from argostranslate)
Using cached PyQt5-5.15.4.tar.gz (3.3 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... error
error: subprocess-exited-with-error

× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [32 lines of output]
pyproject.toml: line 7: using '[tool.sip.metadata]' to specify the project metadata is deprecated and will be removed in SIP v7.0.0, use '[project]' instead
Traceback (most recent call last):
File "/Users/lishrliu/StableDiffusion/ComfyUI/venv/lib/python3.13/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in
main()

File "/Users/lishrliu/StableDiffusion/ComfyUI/venv/lib/python3.13/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
~~~~^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/lishrliu/StableDiffusion/ComfyUI/venv/lib/python3.13/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 152, in prepare_metadata_for_build_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-zyxcpvem/overlay/lib/python3.13/site-packages/sipbuild/api.py", line 28, in build_wheel
project = AbstractProject.bootstrap('wheel',
arguments=_convert_config_settings(config_settings))
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-zyxcpvem/overlay/lib/python3.13/site-packages/sipbuild/abstract_project.py", line 74, in bootstrap
project.setup(pyproject, tool, tool_description)
~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-zyxcpvem/overlay/lib/python3.13/site-packages/sipbuild/project.py", line 608, in setup
self.apply_user_defaults(tool)
~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-install-z9d1io9y/pyqt5_79395ba726964d37a665ef0cd9f2e6e8/project.py", line 63, in apply_user_defaults
super().apply_user_defaults(tool)
~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-zyxcpvem/overlay/lib/python3.13/site-packages/pyqtbuild/project.py", line 51, in apply_user_defaults
super().apply_user_defaults(tool)
~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-zyxcpvem/overlay/lib/python3.13/site-packages/sipbuild/project.py", line 237, in apply_user_defaults
self.builder.apply_user_defaults(tool)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-zyxcpvem/overlay/lib/python3.13/site-packages/pyqtbuild/builder.py", line 50, in apply_user_defaults
raise PyProjectOptionException('qmake',
"specify a working qmake or add it to PATH")
sipbuild.pyproject.PyProjectOptionException
[end of output]
  
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
#
#
The environment I used is:
Mac book
Python 3.10.11

@AlekPet
Copy link
Owner

AlekPet commented Dec 1, 2024

Hello try reinstall PyQt5, in your enviroment where comfyu installed or in Comfyu Manager .

pip install PyQt5==5.15.4

and then

pip install argostranslate

or uninstall

pip uninstall PyQt5==5.15.4
pip install PyQt5==5.15.4

and then

pip install argostranslate

@lishrliu
Copy link
Author

lishrliu commented Dec 2, 2024

Pip install PyQt5==5.15.4 prompts failure
Pip install PyQt5 prompts successful
Pip install argostranslate prompt requires PyQt5==5.15.4
But PyQt5==5.15.4 cannot be installed correctly

The details are as follows:

(venv) lishrliu@lishrliudeMacBook-Pro ComfyUI % pip install sip==5.5.0
Collecting sip==5.5.0
Downloading sip-5.5.0.tar.gz (1.1 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.1/1.1 MB 2.8 MB/s eta 0:00:00
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... done
Requirement already satisfied: packaging in ./venv/lib/python3.13/site-packages (from sip==5.5.0) (24.2)
Collecting toml (from sip==5.5.0)
Downloading toml-0.10.2-py2.py3-none-any.whl.metadata (7.1 kB)
Downloading toml-0.10.2-py2.py3-none-any.whl (16 kB)
Building wheels for collected packages: sip
Building wheel for sip (pyproject.toml) ... done
Created wheel for sip: filename=sip-5.5.0-cp313-cp313-macosx_15_0_arm64.whl size=484801 sha256=d51d02952300f32c436ce11d158573c1a1df5d3d21b8e0e2840e64f33a31dbb4
Stored in directory: /Users/lishrliu/Library/Caches/pip/wheels/f7/81/c2/e287241660b25c2e1d22e9cc874c1a00567552707ef162a0f7
Successfully built sip
Installing collected packages: toml, sip
Successfully installed sip-5.5.0 toml-0.10.2

(venv) lishrliu@lishrliudeMacBook-Pro ComfyUI % pip install PyQt5==5.15.4
Collecting PyQt5==5.15.4
Using cached PyQt5-5.15.4.tar.gz (3.3 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... error
error: subprocess-exited-with-error

× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [25 lines of output]
pyproject.toml: line 7: using '[tool.sip.metadata]' to specify the project metadata is deprecated and will be removed in SIP v7.0.0, use '[project]' instead
Querying qmake about your Qt installation...
Traceback (most recent call last):
File "/Users/lishrliu/StableDiffusion/ComfyUI/venv/lib/python3.13/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in
main()
~~~~^^
File "/Users/lishrliu/StableDiffusion/ComfyUI/venv/lib/python3.13/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
~~~~^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/lishrliu/StableDiffusion/ComfyUI/venv/lib/python3.13/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 152, in prepare_metadata_for_build_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-_9caht9o/overlay/lib/python3.13/site-packages/sipbuild/api.py", line 28, in build_wheel
project = AbstractProject.bootstrap('wheel',
arguments=_convert_config_settings(config_settings))
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-_9caht9o/overlay/lib/python3.13/site-packages/sipbuild/abstract_project.py", line 74, in bootstrap
project.setup(pyproject, tool, tool_description)
~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-_9caht9o/overlay/lib/python3.13/site-packages/sipbuild/project.py", line 624, in setup
self.update(tool)
~~~~~~~~~~~^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-install-pn20rw7o/pyqt5_8d0a3c4192a043ffbb749cbea866941a/project.py", line 160, in update
raise UserException(
"Qt v5 is required, not v{0}".format(
self.builder.qt_version_str))
sipbuild.exceptions.UserException
[end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

(venv) lishrliu@lishrliudeMacBook-Pro ComfyUI % pip install PyQt5
Collecting PyQt5
Downloading PyQt5-5.15.11-cp38-abi3-macosx_11_0_arm64.whl.metadata (2.1 kB)
Collecting PyQt5-sip<13,>=12.15 (from PyQt5)
Downloading PyQt5_sip-12.15.0.tar.gz (104 kB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... done
Collecting PyQt5-Qt5<5.16.0,>=5.15.2 (from PyQt5)
Downloading PyQt5_Qt5-5.15.15-py3-none-macosx_11_0_arm64.whl.metadata (536 bytes)
Downloading PyQt5-5.15.11-cp38-abi3-macosx_11_0_arm64.whl (6.6 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 6.6/6.6 MB 4.9 MB/s eta 0:00:00
Downloading PyQt5_Qt5-5.15.15-py3-none-macosx_11_0_arm64.whl (37.0 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 37.0/37.0 MB 111.3 kB/s eta 0:00:00
Building wheels for collected packages: PyQt5-sip
Building wheel for PyQt5-sip (pyproject.toml) ... done
Created wheel for PyQt5-sip: filename=PyQt5_sip-12.15.0-cp313-cp313-macosx_15_0_arm64.whl size=60202 sha256=a3deb9eba13ca7e0bc2be505f46ec760abc1f6ed88fd977e18084e74d33b0a99
Stored in directory: /Users/lishrliu/Library/Caches/pip/wheels/5b/f2/f6/93f2f74948dd23880023d3700802befd25cc8228408e85510a
Successfully built PyQt5-sip
Installing collected packages: PyQt5-Qt5, PyQt5-sip, PyQt5
Successfully installed PyQt5-5.15.11 PyQt5-Qt5-5.15.15 PyQt5-sip-12.15.0

(venv) lishrliu@lishrliudeMacBook-Pro ComfyUI % pip install argostranslate
Collecting argostranslate
Using cached argostranslate-1.9.6-py3-none-any.whl.metadata (10 kB)
INFO: pip is looking at multiple versions of argostranslate to determine which version is compatible with other requirements. This could take a while.
Using cached argostranslate-1.9.5-py3-none-any.whl.metadata (10 kB)
Using cached argostranslate-1.9.4-py3-none-any.whl.metadata (10 kB)
Using cached argostranslate-1.9.3-py3-none-any.whl.metadata (9.9 kB)
Using cached argostranslate-1.9.2-py3-none-any.whl.metadata (10.0 kB)
Using cached argostranslate-1.9.1-py3-none-any.whl.metadata (9.7 kB)
Using cached argostranslate-1.9.0-py3-none-any.whl.metadata (9.7 kB)
Using cached argostranslate-1.8.3-py3-none-any.whl.metadata (9.7 kB)
INFO: pip is still looking at multiple versions of argostranslate to determine which version is compatible with other requirements. This could take a while.
Using cached argostranslate-1.8.2-py3-none-any.whl.metadata (9.6 kB)
Using cached argostranslate-1.8.1-py3-none-any.whl.metadata (9.7 kB)
Using cached argostranslate-1.8.0-py3-none-any.whl.metadata (8.9 kB)
Using cached argostranslate-1.7.5-py3-none-any.whl.metadata (9.1 kB)
Using cached argostranslate-1.7.4-py3-none-any.whl.metadata (9.1 kB)
INFO: This is taking longer than usual. You might need to provide the dependency resolver with stricter constraints to reduce runtime. See https://pip.pypa.io/warnings/backtracking for guidance. If you want to abort this run, press Ctrl + C.
Using cached argostranslate-1.7.3-py3-none-any.whl.metadata (9.2 kB)
Using cached argostranslate-1.7.2-py3-none-any.whl.metadata (9.2 kB)
Using cached argostranslate-1.7.0-py3-none-any.whl.metadata (9.3 kB)
Using cached argostranslate-1.6.1-py3-none-any.whl.metadata (14 kB)
Using cached argostranslate-1.6.0-py3-none-any.whl.metadata (14 kB)
Using cached argostranslate-1.5.4-py3-none-any.whl.metadata (14 kB)
Collecting PyQt5==5.15.4 (from argostranslate)
Using cached PyQt5-5.15.4.tar.gz (3.3 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... error
error: subprocess-exited-with-error

× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [25 lines of output]
pyproject.toml: line 7: using '[tool.sip.metadata]' to specify the project metadata is deprecated and will be removed in SIP v7.0.0, use '[project]' instead
Querying qmake about your Qt installation...
Traceback (most recent call last):
File "/Users/lishrliu/StableDiffusion/ComfyUI/venv/lib/python3.13/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in
main()
~~~~^^
File "/Users/lishrliu/StableDiffusion/ComfyUI/venv/lib/python3.13/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
~~~~^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/lishrliu/StableDiffusion/ComfyUI/venv/lib/python3.13/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 152, in prepare_metadata_for_build_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-k6667g7x/overlay/lib/python3.13/site-packages/sipbuild/api.py", line 28, in build_wheel
project = AbstractProject.bootstrap('wheel',
arguments=_convert_config_settings(config_settings))
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-k6667g7x/overlay/lib/python3.13/site-packages/sipbuild/abstract_project.py", line 74, in bootstrap
project.setup(pyproject, tool, tool_description)
~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-k6667g7x/overlay/lib/python3.13/site-packages/sipbuild/project.py", line 624, in setup
self.update(tool)
~~~~~~~~~~~^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-install-cihvnl3j/pyqt5_10b98162f95a47baae2b6b9e1fd9ed05/project.py", line 160, in update
raise UserException(
"Qt v5 is required, not v{0}".format(
self.builder.qt_version_str))
sipbuild.exceptions.UserException
[end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

[START] ComfyUI AlekPet Nodes v1.0.35

Node -> ChatGLMNode: ChatGLM4TranslateCLIPTextEncodeNode, ChatGLM4TranslateTextNode [Loading]
Node -> GoogleTranslateNode: GoogleTranslateCLIPTextEncodeNode, GoogleTranslateTextNode [Loading]
Node -> ArgosTranslateNode: ArgosTranslateCLIPTextEncodeNode, ArgosTranslateTextNode [Loading] Node -> DeepTranslatorNode: DeepTranslatorCLIPTextEncodeNode, DeepTranslatorTextNode [Loading]

Node -> ExtrasNode: PreviewTextNode, HexToHueNode, ColorsCorrectNode [Loading]
Node -> PoseNode: PoseNode [Loading]
Node -> IDENode: IDENode [Loading]
Node -> PainterNode: PainterNode [Loading]
Collecting argostranslate
Downloading argostranslate-1.9.6-py3-none-any.whl.metadata (10 kB)
INFO: pip is looking at multiple versions of argostranslate to determine which version is compatible with other requirements. This could take a while.
Downloading argostranslate-1.9.5-py3-none-any.whl.metadata (10 kB)
Downloading argostranslate-1.9.4-py3-none-any.whl.metadata (10 kB)
Downloading argostranslate-1.9.3-py3-none-any.whl.metadata (9.9 kB)
Downloading argostranslate-1.9.2-py3-none-any.whl.metadata (10.0 kB)
Downloading argostranslate-1.9.1-py3-none-any.whl.metadata (9.7 kB)
Downloading argostranslate-1.9.0-py3-none-any.whl.metadata (9.7 kB)
Downloading argostranslate-1.8.3-py3-none-any.whl.metadata (9.7 kB)
INFO: pip is still looking at multiple versions of argostranslate to determine which version is compatible with other requirements. This could take a while.
Downloading argostranslate-1.8.2-py3-none-any.whl.metadata (9.6 kB)
Downloading argostranslate-1.8.1-py3-none-any.whl.metadata (9.7 kB)
Downloading argostranslate-1.8.0-py3-none-any.whl.metadata (8.9 kB)
Downloading argostranslate-1.7.5-py3-none-any.whl.metadata (9.1 kB)
Downloading argostranslate-1.7.4-py3-none-any.whl.metadata (9.1 kB)
INFO: This is taking longer than usual. You might need to provide the dependency resolver with stricter constraints to reduce runtime. See https://pip.pypa.io/warnings/backtracking for guidance. If you want to abort this run, press Ctrl + C.
Downloading argostranslate-1.7.3-py3-none-any.whl.metadata (9.2 kB)
Downloading argostranslate-1.7.2-py3-none-any.whl.metadata (9.2 kB)
Downloading argostranslate-1.7.0-py3-none-any.whl.metadata (9.3 kB)
Downloading argostranslate-1.6.1-py3-none-any.whl.metadata (14 kB)
Downloading argostranslate-1.6.0-py3-none-any.whl.metadata (14 kB)
Downloading argostranslate-1.5.4-py3-none-any.whl.metadata (14 kB)
Collecting PyQt5==5.15.4 (from argostranslate)
Using cached PyQt5-5.15.4.tar.gz (3.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'
Preparing metadata (pyproject.toml): started
Preparing metadata (pyproject.toml): finished with status 'error'
error: subprocess-exited-with-error

× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [25 lines of output]
pyproject.toml: line 7: using '[tool.sip.metadata]' to specify the project metadata is deprecated and will be removed in SIP v7.0.0, use '[project]' instead
Querying qmake about your Qt installation...
Traceback (most recent call last):
File "/Users/lishrliu/StableDiffusion/ComfyUI/venv/lib/python3.13/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in
main()
~~~~^^
File "/Users/lishrliu/StableDiffusion/ComfyUI/venv/lib/python3.13/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
~~~~^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/lishrliu/StableDiffusion/ComfyUI/venv/lib/python3.13/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 152, in prepare_metadata_for_build_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-yrneqvhe/overlay/lib/python3.13/site-packages/sipbuild/api.py", line 28, in build_wheel
project = AbstractProject.bootstrap('wheel',
arguments=_convert_config_settings(config_settings))
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-yrneqvhe/overlay/lib/python3.13/site-packages/sipbuild/abstract_project.py", line 74, in bootstrap
project.setup(pyproject, tool, tool_description)
~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-build-env-yrneqvhe/overlay/lib/python3.13/site-packages/sipbuild/project.py", line 624, in setup
self.update(tool)
~~~~~~~~~~~^^^^^^
File "/private/var/folders/37/stln1lj53v7chk_d2n_jnbkm0000gn/T/pip-install-giwfdz50/pyqt5_f53aad3a20b74504bb50b8df5150900b/project.py", line 160, in update
raise UserException(
"Qt v5 is required, not v{0}".format(
self.builder.qt_version_str))
sipbuild.exceptions.UserException
[end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

@AlekPet
Copy link
Owner

AlekPet commented Dec 2, 2024

I see it still complains about PyQt, it says that your version is higher than necessary.The error occurs because PyQt5==5.15.4 is being installed from source, and it relies on a specific version of qmake that is missing or not configured properly in your system. However, newer versions of PyQt5 (e.g., 5.15.11) are being installed successfully because they come with prebuilt wheels for your macOS environment. argostranslate is requiring an older PyQt5==5.15.4, which complicates things. If you don't need argostranslate, you don't have to use it, read here #95 (comment), #93 (comment) . If you still need it, look here, it's related to macOS need before install argostranslate argosopentech/argos-translate#112 (comment)

Or:
You can install a newer version of PyQt5 and modify the argostranslate package to use it, before remove or rename requirements.txt in ArgosTranslatorNode folder ! :

  1. Install the latest PyQt5:

pip install PyQt5

  1. Install argostranslate ignoring dependency requirements:

pip install argostranslate --no-deps

  1. Manually install missing dependencies for argostranslate: After installing argostranslate without dependencies, install the remaining requirements using:

pip install requests tqdm

@lishrliu
Copy link
Author

lishrliu commented Dec 4, 2024

I gave up, even manual installation was unsuccessful。

@AlekPet
Copy link
Owner

AlekPet commented Dec 4, 2024

I gave up, even manual installation was unsuccessful。

Try disabling argostranslate as I wrote above if you don't need it #93 (comment) . And so manual installation implies first completely removing argostranslate, installing the latest PyQt5 for your machine and then manually installing argostranslate without packages and installing packages manually in accordance with the packages (not use spacy on used PyQt5)
https://github.com/argosopentech/argos-translate/blob/36e25f9d22a07c291b253e7376160dd92618b519/requirements.txt


Or
Install Prebuilt Wheels for PyQt5==5.15.4

Prebuilt wheels for PyQt5==5.15.4 may not be available for your macOS version, but you can force a compatible version.

  1. Use the command:

pip install PyQt5==5.15.4 --only-binary :all:


Or

Build and Install PyQt5==5.15.4 Locally

If you must use PyQt5==5.15.4:

  1. Install Qt with qmake: Install the appropriate version of Qt. On macOS, use Homebrew:

brew install qt@5

  1. Ensure qmake is in your PATH: Add the Qt binaries to your shell configuration. For example:

export PATH="/usr/local/opt/qt@5/bin:$PATH"

  1. Try installing PyQt5==5.15.4 again:

pip install PyQt5==5.15.4


Or ask questions on https://github.com/argosopentech/argos-translate

@lishrliu
Copy link
Author

Created environment again, specified qt@5 It has been successful, thank you very much.

@AlekPet AlekPet closed this as completed Dec 16, 2024
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

2 participants