How to install PyQtWebEngine in m1 pro? - python

how to install PyQtWebEngine by m1 pro,macos
install error
pip install -i PyQtWebEngine
Looking in indexes:
Collecting PyQtWebEngine
Using cached https://pypi.tuna.tsinghua.edu.cn/packages/cf/4b/ca01d875eff114ba5221ce9311912fbbc142b7bb4cbc4435e04f4f1f73cb/PyQtWebEngine-5.15.6.tar.gz (48 kB)
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
╰─> [27 lines of output]
Traceback (most recent call last):
File "/opt/homebrew/Caskroom/miniforge/base/envs/pyqt/lib/python3.9/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 156, in prepare_metadata_for_build_wheel
hook = backend.prepare_metadata_for_build_wheel
AttributeError: module 'sipbuild.api' has no attribute 'prepare_metadata_for_build_wheel'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/opt/homebrew/Caskroom/miniforge/base/envs/pyqt/lib/python3.9/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 363, in <module>
main()
File "/opt/homebrew/Caskroom/miniforge/base/envs/pyqt/lib/python3.9/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 345, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "/opt/homebrew/Caskroom/miniforge/base/envs/pyqt/lib/python3.9/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 160, in prepare_metadata_for_build_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "/private/var/folders/52/qg4pw1dj73j4t7s079kckmz80000gn/T/pip-build-env-o6asbq8b/overlay/lib/python3.9/site-packages/sipbuild/api.py", line 46, in build_wheel
project = AbstractProject.bootstrap('wheel',
File "/private/var/folders/52/qg4pw1dj73j4t7s079kckmz80000gn/T/pip-build-env-o6asbq8b/overlay/lib/python3.9/site-packages/sipbuild/abstract_project.py", line 87, in bootstrap
project.setup(pyproject, tool, tool_description)
File "/private/var/folders/52/qg4pw1dj73j4t7s079kckmz80000gn/T/pip-build-env-o6asbq8b/overlay/lib/python3.9/site-packages/sipbuild/project.py", line 584, in setup
self.apply_user_defaults(tool)
File "/private/var/folders/52/qg4pw1dj73j4t7s079kckmz80000gn/T/pip-build-env-o6asbq8b/overlay/lib/python3.9/site-packages/pyqtbuild/project.py", line 70, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/52/qg4pw1dj73j4t7s079kckmz80000gn/T/pip-build-env-o6asbq8b/overlay/lib/python3.9/site-packages/sipbuild/project.py", line 236, in apply_user_defaults
self.builder.apply_user_defaults(tool)
File "/private/var/folders/52/qg4pw1dj73j4t7s079kckmz80000gn/T/pip-build-env-o6asbq8b/overlay/lib/python3.9/site-packages/pyqtbuild/builder.py", line 67, in apply_user_defaults
raise PyProjectOptionException('qmake',
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.
i Follow the URL operation to install or can not install normally
https://github.com/emacs-eaf/emacs-application-framework/issues/868
How to install PyQtWebEngine in m1 ? I tried pip3 install PyQtWebEngine.

Related

pyqt5 5.15.7 error: subprocess-exited-with-error

I tried to install pyqt5 on my mac air m2 and i got this error :
pip3 install pyqt5
Collecting pyqt5
Using cached PyQt5-5.15.7.tar.gz (3.2 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
╰─> [33 lines of output]
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 144, in prepare_metadata_for_build_wheel
hook = backend.prepare_metadata_for_build_wheel
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: module 'sipbuild.api' has no attribute 'prepare_metadata_for_build_wheel'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 351, in <module>
main()
File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 333, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 148, in prepare_metadata_for_build_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/private/var/folders/zq/z6_slmcx6fjfx18wnzwh77kh0000gn/T/pip-build-env-jdrfm05e/overlay/lib/python3.11/site-packages/sipbuild/api.py", line 46, in build_wheel
project = AbstractProject.bootstrap('wheel',
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/private/var/folders/zq/z6_slmcx6fjfx18wnzwh77kh0000gn/T/pip-build-env-jdrfm05e/overlay/lib/python3.11/site-packages/sipbuild/abstract_project.py", line 87, in bootstrap
project.setup(pyproject, tool, tool_description)
File "/private/var/folders/zq/z6_slmcx6fjfx18wnzwh77kh0000gn/T/pip-build-env-jdrfm05e/overlay/lib/python3.11/site-packages/sipbuild/project.py", line 585, in setup
self.apply_user_defaults(tool)
File "/private/var/folders/zq/z6_slmcx6fjfx18wnzwh77kh0000gn/T/pip-install-2vvfy4aa/pyqt5_740441afdd6c412991129051ada10a0f/project.py", line 69, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/zq/z6_slmcx6fjfx18wnzwh77kh0000gn/T/pip-build-env-jdrfm05e/overlay/lib/python3.11/site-packages/pyqtbuild/project.py", line 70, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/zq/z6_slmcx6fjfx18wnzwh77kh0000gn/T/pip-build-env-jdrfm05e/overlay/lib/python3.11/site-packages/sipbuild/project.py", line 236, in apply_user_defaults
self.builder.apply_user_defaults(tool)
File "/private/var/folders/zq/z6_slmcx6fjfx18wnzwh77kh0000gn/T/pip-build-env-jdrfm05e/overlay/lib/python3.11/site-packages/pyqtbuild/builder.py", line 69, in apply_user_defaults
raise PyProjectOptionException('qmake',
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.
so i tried it with brew and all combination with pip
i also reinstall everything.
thanks for any help^^
pip3 install pyqt5
pip3 install pyqt5==5.15.7 (also different versions)
reinstall pip
reinstall pytube
try it again (not working)
install Homebrew
install everythink
try it again (do not working)
uninstall homerew
search in google (found nothing)
asking now for help

pip install lanms package issues

I am trying to install a python package (Via pycharm) and I get the following error. How do I resolve this issue. Thanks.
pip install lanms==1.0.2
Collecting lanms==1.0.2
Using cached lanms-1.0.2.tar.gz (973 kB)
Preparing metadata (setup.py) ... error
error: subprocess-exited-with-error
× python setup.py egg_info did not run successfully.
│ exit code: 1
╰─> [12 lines of output]
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "<pip-setuptools-caller>", line 34, in <module>
File "C:\Users\hello\AppData\Local\Temp\pip-install-0fm0m1ax\lanms_f1f4c8d9787c4f8ab5a30a96423d846e\setup.py", line 27, in <m
odule>
if subprocess.call(['make', '--always-make','-C', BASE_DIR]) != 0:
File "C:\Users\hello\AppData\Local\Programs\Python\Python38\lib\subprocess.py", line 340, in call
with Popen(*popenargs, **kwargs) as p:
File "C:\Users\hello\AppData\Local\Programs\Python\Python38\lib\subprocess.py", line 858, in __init__
self._execute_child(args, executable, preexec_fn, close_fds,
File "C:\Users\hello\AppData\Local\Programs\Python\Python38\lib\subprocess.py", line 1311, in _execute_child
hp, ht, pid, tid = _winapi.CreateProcess(executable, args,
FileNotFoundError: [WinError 2] The system cannot find the file specified
[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.
I have already upgraded setuptools, wheel and pip as below.
pip 22.2.2
setuptools 65.3.0
wheel 0.37.1

Require help installing pyqt6

I have been trying to install pyqt6 on my linux device!
tried running:
pip install pyqt6
pip3 install pyqt6
python -m pip install pyqt6
python3 -m pip install pyqt6
and the variations of such commands. I also tried updating pip and python to latest versions it would give me (python 3.9.2 and pip 22.1.2)
error i get when installing pyqt6 is as follows:
Defaulting to user installation because normal site-packages is not writeable
Collecting pyqt6
Using cached PyQt6-6.3.1.tar.gz (1.0 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
╰─> [29 lines of output]
Traceback (most recent call last):
File "/home/user1/.local/lib/python3.9/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 156, in prepare_metadata_for_build_wheel
hook = backend.prepare_metadata_for_build_wheel
AttributeError: module 'sipbuild.api' has no attribute 'prepare_metadata_for_build_wheel'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/user1/.local/lib/python3.9/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 363, in <module>
main()
File "/home/user1/.local/lib/python3.9/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 345, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "/home/user1/.local/lib/python3.9/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 160, in prepare_metadata_for_build_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "/tmp/pip-build-env-lb2ttoa7/overlay/lib/python3.9/site-packages/sipbuild/api.py", line 46, in build_wheel
project = AbstractProject.bootstrap('wheel',
File "/tmp/pip-build-env-lb2ttoa7/overlay/lib/python3.9/site-packages/sipbuild/abstract_project.py", line 87, in bootstrap
project.setup(pyproject, tool, tool_description)
File "/tmp/pip-build-env-lb2ttoa7/overlay/lib/python3.9/site-packages/sipbuild/project.py", line 584, in setup
self.apply_user_defaults(tool)
File "project.py", line 67, in apply_user_defaults
super().apply_user_defaults(tool)
File "/tmp/pip-build-env-lb2ttoa7/overlay/lib/python3.9/site-packages/pyqtbuild/project.py", line 70, in apply_user_defaults
super().apply_user_defaults(tool)
File "/tmp/pip-build-env-lb2ttoa7/overlay/lib/python3.9/site-packages/sipbuild/project.py", line 236, in apply_user_defaults
self.builder.apply_user_defaults(tool)
File "/tmp/pip-build-env-lb2ttoa7/overlay/lib/python3.9/site-packages/pyqtbuild/builder.py", line 67, in apply_user_defaults
raise PyProjectOptionException('qmake',
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.
Any help would be appreciated
edits:
to answer comments (since i replied there by accident instead of updating:
unsure what linux distro i'm running since it's the linux de available on chromebooks, if there's an official package for it I don't know what it is.
link 1 doesn't help just recommends i try steps i've done already such as updating pip

to import pyqt5.uic, do I have to install pyqt5-tools first?

to import pyqt5.uic, do I have to install pyqt5-tools first?
(venv) PS C:\Users\77140\AppData\Roaming\Anki2\addons21\myaddon> pip freeze | grep PyQt
PyQt5-Qt5==5.15.2
PyQt5-sip==12.10.1
PyQt5-stubs==5.15.6.0
PyQtWebEngine==5.15.5
PyQtWebEngine-Qt5==5.15.2
But My python version is 3.10, from pyqt5-tools offical site, it doesn't support python 3.10, is it why when I exec pip install pyqt5-tools, always get the below error?:
Thanks a lot.
(venv) PS C:\Users\77140\AppData\Roaming\Anki2\addons21\myaddon> pip install pyqt5-tools
Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple
Collecting pyqt5-tools
Using cached https://pypi.tuna.tsinghua.edu.cn/packages/b7/70/a25aab849a5e38ae78716acde1f917a14d9d819c8600bbb8cf536781f7c5/pyqt5_tools-5.15.4.3.2-py3-none-any.whl (29 kB)
Requirement already satisfied: click in c:\users\77140\appdata\roaming\anki2\addons21\myaddon\venv\lib\site-packages (from pyqt5-tools) (8.1.3)
Using cached https://pypi.tuna.tsinghua.edu.cn/packages/36/b8/a255b8160e863678aa7d559a4c8c33b5448a6e270992d1464ec9f87ed633/pyqt5_tools-5.15.4.3.1-py3-none-any.whl (28 kB)
Using cached https://pypi.tuna.tsinghua.edu.cn/packages/88/ca/a9cb4816479940d1e0c94c683418c2cc4b4bc2955cd3c5754179a5f95040/pyqt5_tools-5.15.4.3.0.3-py3-none-any.whl (28 kB)
Using cached https://pypi.tuna.tsinghua.edu.cn/packages/e5/cb/34b583ce53ca66803cfe904b11ae87633b1e98121a2a54583674514ae29b/pyqt5_tools-5.15.3.3.2-py3-none-any.whl (29 kB)
Collecting pyqt5==5.15.3
Using cached https://pypi.tuna.tsinghua.edu.cn/packages/6e/86/d715e71771cece0e060f2ebab20f3ded067b08a0927dfb3143530cae8098/PyQt5-5.15.3.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
╰─> [29 lines of output]
Traceback (most recent call last):
File "c:\users\77140\appdata\roaming\anki2\addons21\myaddon\venv\lib\site-packages\pip\_vendor\pep517\in_process\_in_process.py", line 156, in prepare_metadata_for_build_wheel
hook = backend.prepare_metadata_for_build_wheel
AttributeError: module 'sipbuild.api' has no attribute 'prepare_metadata_for_build_wheel'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "c:\users\77140\appdata\roaming\anki2\addons21\myaddon\venv\lib\site-packages\pip\_vendor\pep517\in_process\_in_process.py", line 363, in <module>
main()
File "c:\users\77140\appdata\roaming\anki2\addons21\myaddon\venv\lib\site-packages\pip\_vendor\pep517\in_process\_in_process.py", line 345, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "c:\users\77140\appdata\roaming\anki2\addons21\myaddon\venv\lib\site-packages\pip\_vendor\pep517\in_process\_in_process.py", line 160, in prepare_metadata_for_build_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "C:\Users\77140\AppData\Local\Temp\pip-build-env-fnfit907\overlay\Lib\site-packages\sipbuild\api.py", line 51, in build_wheel
project = AbstractProject.bootstrap('pep517')
File "C:\Users\77140\AppData\Local\Temp\pip-build-env-fnfit907\overlay\Lib\site-packages\sipbuild\abstract_project.py", line 83, in bootstrap
project.setup(pyproject, tool, tool_description)
File "C:\Users\77140\AppData\Local\Temp\pip-build-env-fnfit907\overlay\Lib\site-packages\sipbuild\project.py", line 594, in setup
self.apply_user_defaults(tool)
File "C:\Users\77140\AppData\Local\Temp\pip-install-8c05wpmz\pyqt5_4b97949f3a094e468dd52d10bb2e71c4\project.py", line 63, in apply_user_defaults
super().apply_user_defaults(tool)
File "C:\Users\77140\AppData\Local\Temp\pip-build-env-fnfit907\overlay\Lib\site-packages\pyqtbuild\project.py", line 70, in apply_user_defaults
super().apply_user_defaults(tool)
File "C:\Users\77140\AppData\Local\Temp\pip-build-env-fnfit907\overlay\Lib\site-packages\sipbuild\project.py", line 241, in apply_user_defaults
self.builder.apply_user_defaults(tool)
File "C:\Users\77140\AppData\Local\Temp\pip-build-env-fnfit907\overlay\Lib\site-packages\pyqtbuild\builder.py", line 67, in apply_user_defaults
sipbuild.pyproject.PyProjectOptionException
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.

Python cannot install package berkeleydb, FileNotFoundError on Getting requirements to build wheel

Trying to install berkeleydb package for python on Windows.
Python 3.9.10
Pip 21.3.1
d:\pip install berkeleydb
Collecting berkeleydb
Using cached berkeleydb-18.1.5.tar.gz (430 kB)
Installing build dependencies ... done
Getting requirements to build wheel ... error
ERROR: Command errored out with exit status 1:
command: 'C:\Users\Admin\AppData\Local\Programs\Python\Python39\python.exe' 'C:\Users\Admin\AppData\Local\Programs\Python\Python39\lib\site-packages\pip\_vendor\pep517\in_process\_in_process.py' get_requires_for_build_wheel 'C:\Users\Admin\AppData\Local\Temp\tmpxcy8yhoh'
cwd: C:\Users\Admin\AppData\Local\Temp\pip-install-jxt67cx4\berkeleydb_a9b2c56166664d789a2f35b3ac5cfc73
Complete output (20 lines):
Traceback (most recent call last):
File "C:\Users\Admin\AppData\Local\Programs\Python\Python39\lib\site-packages\pip\_vendor\pep517\in_process\_in_process.py", line 363, in <module>
main()
File "C:\Users\Admin\AppData\Local\Programs\Python\Python39\lib\site-packages\pip\_vendor\pep517\in_process\_in_process.py", line 345, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "C:\Users\Admin\AppData\Local\Programs\Python\Python39\lib\site-packages\pip\_vendor\pep517\in_process\_in_process.py", line 130, in get_requires_for_build_wheel
return hook(config_settings)
File "C:\Users\Admin\AppData\Local\Temp\pip-build-env-03j2vyim\overlay\Lib\site-packages\setuptools\build_meta.py", line 162, in get_requires_for_build_wheel
return self._get_build_requires(
File "C:\Users\Admin\AppData\Local\Temp\pip-build-env-03j2vyim\overlay\Lib\site-packages\setuptools\build_meta.py", line 143, in _get_build_requires
self.run_setup()
File "C:\Users\Admin\AppData\Local\Temp\pip-build-env-03j2vyim\overlay\Lib\site-packages\setuptools\build_meta.py", line 267, in run_setup
super(_BuildMetaLegacyBackend,
File "C:\Users\Admin\AppData\Local\Temp\pip-build-env-03j2vyim\overlay\Lib\site-packages\setuptools\build_meta.py", line 158, in run_setup
exec(compile(code, __file__, 'exec'), locals())
File "setup.py", line 77, in <module>
import setup3
File "C:\Users\Admin\AppData\Local\Temp\pip-install-jxt67cx4\berkeleydb_a9b2c56166664d789a2f35b3ac5cfc73\setup3.py", line 346, in <module>
with open(os.path.join(incdir, 'db.h'), 'r') as f :
FileNotFoundError: [Errno 2] No such file or directory: 'db/include\\db.h'
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/c2/3f/a96d5caff3bbf0980fb47518ddb015a1df291f5ef31ee8c50ead21cb513a/berkeleydb-18.1.5.tar.gz#sha256=d8c2efbca9472f8848b13cce4f4904a5ea1e1540ee576e626a1491817832a50a (from https://pypi.org/simple/berkeleydb/). Command errored out with exit status 1: 'C:\Users\Admin\AppData\Local\Programs\Python\Python39\python.exe' 'C:\Users\Admin\AppData\Local\Programs\Python\Python39\lib\site-packages\pip\_vendor\pep517\in_process\_in_process.py' get_requires_for_build_wheel 'C:\Users\Admin\AppData\Local\Temp\tmpxcy8yhoh' Check the logs for full command output.
I have no clues anymore. Totally removed python from my system and reinstalled it. Also with pip install bsddb3 I get a similar problem. However, I could install pandas without problems.
You can try installing bsddb first as follows
pip install bsddb3-6.1.1-cp34-none-win_amd64.whl
if that does'nt work try this
$ sudo apt install libdb-dev
$ pip install bsddb3

Categories

Resources