Related
I have a docker image in which I'm trying to install pyicu (version 2.3 but other versions fail to install as well). Installation of pyicu works there. I used to build FROM python:3.6 in the Dockerfile but now upgrading to use ubuntu:21.04 and getting the error below. Using Python 3.6 and running apt-get -y update && apt-get install -y --no-install-recommends libicu-dev in both.
I see that a potential issue could be that the pkg-config package has been deleted from Ubuntu 21 https://www.ubuntuupdates.org/package/core/impish/main/proposed/pkg-config. Is this the root of the issue and if so how can I resolve it?
Downloading https://docker.artifactory.enigma.com/artifactory/api/pypi/pypi/packages/packages/87/10/fdf5842f42834f6e3141668b607c07bc3c94de39acf582c3d4015e7a7fc5/PyICU-2.3.tar.gz (214 kB)
Preparing metadata (setup.py): started
Preparing metadata (setup.py): finished with status 'error'
ERROR: Command errored out with exit status 1:
command: /root/.pyenv/versions/3.6.10/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-g23e769w/pyicu_fa1d77f63b4346f48975bf7f3d7508cc/setup.py'"'"'; __file__='"'"'/tmp/pip-install-g23e769w/pyicu_fa1d77f63b4346f48975bf7f3d7508cc/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-lv3srr2x
cwd: /tmp/pip-install-g23e769w/pyicu_fa1d77f63b4346f48975bf7f3d7508cc/
Complete output (53 lines):
(running 'icu-config --version')
(running 'pkg-config --modversion icu-i18n')
Traceback (most recent call last):
File "/tmp/pip-install-g23e769w/pyicu_fa1d77f63b4346f48975bf7f3d7508cc/setup.py", line 62, in <module>
ICU_VERSION = os.environ['ICU_VERSION']
File "/root/.pyenv/versions/3.6.10/lib/python3.6/os.py", line 669, in __getitem__
raise KeyError(key) from None
KeyError: 'ICU_VERSION'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/tmp/pip-install-g23e769w/pyicu_fa1d77f63b4346f48975bf7f3d7508cc/setup.py", line 65, in <module>
ICU_VERSION = check_output(('icu-config', '--version')).strip()
File "/tmp/pip-install-g23e769w/pyicu_fa1d77f63b4346f48975bf7f3d7508cc/setup.py", line 18, in check_output
return subprocess_check_output(popenargs)
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 356, in check_output
**kwargs).stdout
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 423, in run
with Popen(*popenargs, **kwargs) as process:
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 729, in __init__
restore_signals, start_new_session)
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 1364, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'icu-config': 'icu-config'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/tmp/pip-install-g23e769w/pyicu_fa1d77f63b4346f48975bf7f3d7508cc/setup.py", line 68, in <module>
ICU_VERSION = check_output(('pkg-config', '--modversion', 'icu-i18n')).strip()
File "/tmp/pip-install-g23e769w/pyicu_fa1d77f63b4346f48975bf7f3d7508cc/setup.py", line 18, in check_output
return subprocess_check_output(popenargs)
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 356, in check_output
**kwargs).stdout
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 423, in run
with Popen(*popenargs, **kwargs) as process:
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 729, in __init__
restore_signals, start_new_session)
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 1364, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'pkg-config': 'pkg-config'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-g23e769w/pyicu_fa1d77f63b4346f48975bf7f3d7508cc/setup.py", line 73, in <module>
''')
RuntimeError:
Please set the ICU_VERSION environment variable to the version of
ICU you have installed.
----------------------------------------
WARNING: Discarding https://docker.artifactory.enigma.com/artifactory/api/pypi/pypi/packages/packages/87/10/fdf5842f42834f6e3141668b607c07bc3c94de39acf582c3d4015e7a7fc5/PyICU-2.3.tar.gz#sha256=419d389b014ee48f31014920f300c842df0770a283ab1fb4de82a6af334cac4d (from https://docker.artifactory.enigma.com/artifactory/api/pypi/pypi/simple/pyicu/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading PyICU-2.3.tar.gz (214 kB)
Preparing metadata (setup.py): started
Preparing metadata (setup.py): finished with status 'error'
ERROR: Command errored out with exit status 1:
command: /root/.pyenv/versions/3.6.10/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-g23e769w/pyicu_674899e91a7845b198565e0928c250ac/setup.py'"'"'; __file__='"'"'/tmp/pip-install-g23e769w/pyicu_674899e91a7845b198565e0928c250ac/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-rv07hczd
cwd: /tmp/pip-install-g23e769w/pyicu_674899e91a7845b198565e0928c250ac/
Complete output (53 lines):
(running 'icu-config --version')
(running 'pkg-config --modversion icu-i18n')
Traceback (most recent call last):
File "/tmp/pip-install-g23e769w/pyicu_674899e91a7845b198565e0928c250ac/setup.py", line 62, in <module>
ICU_VERSION = os.environ['ICU_VERSION']
File "/root/.pyenv/versions/3.6.10/lib/python3.6/os.py", line 669, in __getitem__
raise KeyError(key) from None
KeyError: 'ICU_VERSION'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/tmp/pip-install-g23e769w/pyicu_674899e91a7845b198565e0928c250ac/setup.py", line 65, in <module>
ICU_VERSION = check_output(('icu-config', '--version')).strip()
File "/tmp/pip-install-g23e769w/pyicu_674899e91a7845b198565e0928c250ac/setup.py", line 18, in check_output
return subprocess_check_output(popenargs)
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 356, in check_output
**kwargs).stdout
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 423, in run
with Popen(*popenargs, **kwargs) as process:
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 729, in __init__
restore_signals, start_new_session)
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 1364, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'icu-config': 'icu-config'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/tmp/pip-install-g23e769w/pyicu_674899e91a7845b198565e0928c250ac/setup.py", line 68, in <module>
ICU_VERSION = check_output(('pkg-config', '--modversion', 'icu-i18n')).strip()
File "/tmp/pip-install-g23e769w/pyicu_674899e91a7845b198565e0928c250ac/setup.py", line 18, in check_output
return subprocess_check_output(popenargs)
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 356, in check_output
**kwargs).stdout
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 423, in run
with Popen(*popenargs, **kwargs) as process:
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 729, in __init__
restore_signals, start_new_session)
File "/root/.pyenv/versions/3.6.10/lib/python3.6/subprocess.py", line 1364, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'pkg-config': 'pkg-config'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-g23e769w/pyicu_674899e91a7845b198565e0928c250ac/setup.py", line 73, in <module>
''')
RuntimeError:
Please set the ICU_VERSION environment variable to the version of
ICU you have installed.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/87/10/fdf5842f42834f6e3141668b607c07bc3c94de39acf582c3d4015e7a7fc5/PyICU-2.3.tar.gz#sha256=419d389b014ee48f31014920f300c842df0770a283ab1fb4de82a6af334cac4d (from https://pypi.org/simple/pyicu/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
ERROR: Could not find a version that satisfies the requirement pyicu==2.3 (from versions: 0.8, 0.8.1, 0.9, 1.0, 1.0.1, 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 1.8, 1.9, 1.9.1, 1.9.2, 1.9.3, 1.9.4, 1.9.5, 1.9.6, 1.9.7, 1.9.8, 2.0, 2.0.1, 2.0.2, 2.0.3, 2.0.4, 2.0.5, 2.0.6, 2.1, 2.2, 2.3, 2.3.1, 2.4, 2.4.1, 2.4.2, 2.4.3, 2.5, 2.6, 2.7, 2.7.1, 2.7.2, 2.7.3, 2.7.4, 2.8)
ERROR: No matching distribution found for pyicu==2.3
I try to install PyQt in my Mac by pip or brew to install, it all failed with sipbuild.pyproject.PyProjectOptionException error. Need help can someone solve this?
jett#jmac ~ % pip install pyqt5
Defaulting to user installation because normal site-packages is not writeable
Collecting pyqt5
Using cached PyQt5-5.15.4.tar.gz (3.3 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing wheel metadata ... error
ERROR: Command errored out with exit status 1:
command: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 /Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/tmpgdmdc09l
cwd: /private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-install-bv0c7yxz/pyqt5_7923519b6ae5437192ce4b58d6719383
Complete output (31 lines):
Traceback (most recent call last):
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 126, 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/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 280, in <module>
main()
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 263, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 130, in prepare_metadata_for_build_wheel
return _get_wheel_metadata_from_wheel(backend, metadata_directory,
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 159, in _get_wheel_metadata_from_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-4yn2ftzm/overlay/lib/python3.8/site-packages/sipbuild/api.py", line 51, in build_wheel
project = AbstractProject.bootstrap('pep517')
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-4yn2ftzm/overlay/lib/python3.8/site-packages/sipbuild/abstract_project.py", line 83, in bootstrap
project.setup(pyproject, tool, tool_description)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-4yn2ftzm/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 484, in setup
self.apply_user_defaults(tool)
File "project.py", line 63, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-4yn2ftzm/overlay/lib/python3.8/site-packages/pyqtbuild/project.py", line 70, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-4yn2ftzm/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 230, in apply_user_defaults
self.builder.apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-4yn2ftzm/overlay/lib/python3.8/site-packages/pyqtbuild/builder.py", line 66, in apply_user_defaults
raise PyProjectOptionException('qmake',
sipbuild.pyproject.PyProjectOptionException
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/8e/a4/d5e4bf99dd50134c88b95e926d7b81aad2473b47fde5e3e4eac2c69a8942/PyQt5-5.15.4.tar.gz#sha256=2a69597e0dd11caabe75fae133feca66387819fc9bc050f547e5551bce97e5be (from https://pypi.org/simple/pyqt5/) (requires-python:>=3.6). Command errored out with exit status 1: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 /Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/tmpgdmdc09l Check the logs for full command output.
Using cached PyQt5-5.15.3.tar.gz (3.3 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing wheel metadata ... error
ERROR: Command errored out with exit status 1:
command: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 /Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/tmp2b3zk776
cwd: /private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-install-bv0c7yxz/pyqt5_44052bd6cdc34aa2be5b23f36dca88df
Complete output (31 lines):
Traceback (most recent call last):
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 126, 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/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 280, in <module>
main()
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 263, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 130, in prepare_metadata_for_build_wheel
return _get_wheel_metadata_from_wheel(backend, metadata_directory,
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 159, in _get_wheel_metadata_from_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-cx5p34wp/overlay/lib/python3.8/site-packages/sipbuild/api.py", line 51, in build_wheel
project = AbstractProject.bootstrap('pep517')
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-cx5p34wp/overlay/lib/python3.8/site-packages/sipbuild/abstract_project.py", line 83, in bootstrap
project.setup(pyproject, tool, tool_description)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-cx5p34wp/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 484, in setup
self.apply_user_defaults(tool)
File "project.py", line 63, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-cx5p34wp/overlay/lib/python3.8/site-packages/pyqtbuild/project.py", line 70, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-cx5p34wp/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 230, in apply_user_defaults
self.builder.apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-cx5p34wp/overlay/lib/python3.8/site-packages/pyqtbuild/builder.py", line 66, in apply_user_defaults
raise PyProjectOptionException('qmake',
sipbuild.pyproject.PyProjectOptionException
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/6e/86/d715e71771cece0e060f2ebab20f3ded067b08a0927dfb3143530cae8098/PyQt5-5.15.3.tar.gz#sha256=965ba50e7029b37f218a54ace24e87c77db3e5a9f0b83baeb21fb57b4154b838 (from https://pypi.org/simple/pyqt5/) (requires-python:>=3.6). Command errored out with exit status 1: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 /Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/tmp2b3zk776 Check the logs for full command output.
Using cached PyQt5-5.15.2.tar.gz (3.3 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing wheel metadata ... error
ERROR: Command errored out with exit status 1:
command: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 /Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/tmp_r170a4s
cwd: /private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-install-bv0c7yxz/pyqt5_7cbcbc9529f7468180a67bbd9372be5b
Complete output (31 lines):
Traceback (most recent call last):
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 126, 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/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 280, in <module>
main()
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 263, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 130, in prepare_metadata_for_build_wheel
return _get_wheel_metadata_from_wheel(backend, metadata_directory,
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 159, in _get_wheel_metadata_from_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-hihu6t3f/overlay/lib/python3.8/site-packages/sipbuild/api.py", line 51, in build_wheel
project = AbstractProject.bootstrap('pep517')
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-hihu6t3f/overlay/lib/python3.8/site-packages/sipbuild/abstract_project.py", line 83, in bootstrap
project.setup(pyproject, tool, tool_description)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-hihu6t3f/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 484, in setup
self.apply_user_defaults(tool)
File "project.py", line 63, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-hihu6t3f/overlay/lib/python3.8/site-packages/pyqtbuild/project.py", line 70, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-hihu6t3f/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 230, in apply_user_defaults
self.builder.apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-hihu6t3f/overlay/lib/python3.8/site-packages/pyqtbuild/builder.py", line 66, in apply_user_defaults
raise PyProjectOptionException('qmake',
sipbuild.pyproject.PyProjectOptionException
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/28/6c/640e3f5c734c296a7193079a86842a789edb7988dca39eab44579088a1d1/PyQt5-5.15.2.tar.gz#sha256=372b08dc9321d1201e4690182697c5e7ffb2e0770e6b4a45519025134b12e4fc (from https://pypi.org/simple/pyqt5/) (requires-python:>=3.5). Command errored out with exit status 1: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 /Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/tmp_r170a4s Check the logs for full command output.
Using cached PyQt5-5.15.1.tar.gz (3.3 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing wheel metadata ... error
ERROR: Command errored out with exit status 1:
command: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 /Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/tmprj4uldbh
cwd: /private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-install-bv0c7yxz/pyqt5_b03b2a05214c4d1ebc157f6b7a32e368
Complete output (31 lines):
Traceback (most recent call last):
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 126, 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/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 280, in <module>
main()
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 263, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 130, in prepare_metadata_for_build_wheel
return _get_wheel_metadata_from_wheel(backend, metadata_directory,
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 159, in _get_wheel_metadata_from_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-np1hm2fb/overlay/lib/python3.8/site-packages/sipbuild/api.py", line 51, in build_wheel
project = AbstractProject.bootstrap('pep517')
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-np1hm2fb/overlay/lib/python3.8/site-packages/sipbuild/abstract_project.py", line 83, in bootstrap
project.setup(pyproject, tool, tool_description)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-np1hm2fb/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 484, in setup
self.apply_user_defaults(tool)
File "project.py", line 64, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-np1hm2fb/overlay/lib/python3.8/site-packages/pyqtbuild/project.py", line 70, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-np1hm2fb/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 230, in apply_user_defaults
self.builder.apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-np1hm2fb/overlay/lib/python3.8/site-packages/pyqtbuild/builder.py", line 66, in apply_user_defaults
raise PyProjectOptionException('qmake',
sipbuild.pyproject.PyProjectOptionException
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/1d/31/896dc3dfb6c81c70164019a6cbba6ab037e3af7653d9ca60ccc874ee4c27/PyQt5-5.15.1.tar.gz#sha256=d9a76b850246d08da9863189ecb98f6c2aa9b4d97a3e85e29330a264aed0f9a1 (from https://pypi.org/simple/pyqt5/) (requires-python:>=3.5). Command errored out with exit status 1: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 /Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/tmprj4uldbh Check the logs for full command output.
Using cached PyQt5-5.15.0.tar.gz (3.3 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing wheel metadata ... error
ERROR: Command errored out with exit status 1:
command: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 /Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/tmp3ql7xuy2
cwd: /private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-install-bv0c7yxz/pyqt5_688200d6210b451b8a4ab6479b451a89
Complete output (31 lines):
Traceback (most recent call last):
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 126, 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/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 280, in <module>
main()
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 263, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 130, in prepare_metadata_for_build_wheel
return _get_wheel_metadata_from_wheel(backend, metadata_directory,
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 159, in _get_wheel_metadata_from_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-o6cj0zt7/overlay/lib/python3.8/site-packages/sipbuild/api.py", line 51, in build_wheel
project = AbstractProject.bootstrap('pep517')
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-o6cj0zt7/overlay/lib/python3.8/site-packages/sipbuild/abstract_project.py", line 83, in bootstrap
project.setup(pyproject, tool, tool_description)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-o6cj0zt7/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 484, in setup
self.apply_user_defaults(tool)
File "project.py", line 62, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-o6cj0zt7/overlay/lib/python3.8/site-packages/pyqtbuild/project.py", line 70, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-o6cj0zt7/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 230, in apply_user_defaults
self.builder.apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-o6cj0zt7/overlay/lib/python3.8/site-packages/pyqtbuild/builder.py", line 66, in apply_user_defaults
raise PyProjectOptionException('qmake',
sipbuild.pyproject.PyProjectOptionException
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/8c/90/82c62bbbadcca98e8c6fa84f1a638de1ed1c89e85368241e9cc43fcbc320/PyQt5-5.15.0.tar.gz#sha256=c6f75488ffd5365a65893bc64ea82a6957db126fbfe33654bcd43ae1c30c52f9 (from https://pypi.org/simple/pyqt5/) (requires-python:>=3.5). Command errored out with exit status 1: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 /Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/tmp3ql7xuy2 Check the logs for full command output.
Using cached PyQt5-5.14.2.tar.gz (3.2 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing wheel metadata ... error
ERROR: Command errored out with exit status 1:
command: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 /Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/tmp9oeqr7vm
cwd: /private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-install-bv0c7yxz/pyqt5_f8c59757cc3e421eb7323c1e0166ff3d
Complete output (31 lines):
Traceback (most recent call last):
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 126, 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/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 280, in <module>
main()
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 263, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 130, in prepare_metadata_for_build_wheel
return _get_wheel_metadata_from_wheel(backend, metadata_directory,
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 159, in _get_wheel_metadata_from_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-6w6xra03/overlay/lib/python3.8/site-packages/sipbuild/api.py", line 51, in build_wheel
project = AbstractProject.bootstrap('pep517')
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-6w6xra03/overlay/lib/python3.8/site-packages/sipbuild/abstract_project.py", line 83, in bootstrap
project.setup(pyproject, tool, tool_description)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-6w6xra03/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 479, in setup
self.apply_user_defaults(tool)
File "project.py", line 62, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-6w6xra03/overlay/lib/python3.8/site-packages/pyqtbuild/project.py", line 70, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-6w6xra03/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 225, in apply_user_defaults
self.builder.apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-6w6xra03/overlay/lib/python3.8/site-packages/pyqtbuild/builder.py", line 66, in apply_user_defaults
raise PyProjectOptionException('qmake',
sipbuild.pyproject.PyProjectOptionException
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/4d/81/b9a66a28fb9a7bbeb60e266f06ebc4703e7e42b99e3609bf1b58ddd232b9/PyQt5-5.14.2.tar.gz#sha256=bd230c6fd699eabf1ceb51e13a8b79b74c00a80272c622427b80141a22269eb0 (from https://pypi.org/simple/pyqt5/) (requires-python:>=3.5). Command errored out with exit status 1: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 /Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/tmp9oeqr7vm Check the logs for full command output.
Using cached PyQt5-5.14.1.tar.gz (3.2 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing wheel metadata ... error
ERROR: Command errored out with exit status 1:
command: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 /Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/tmpgyk62cud
cwd: /private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-install-bv0c7yxz/pyqt5_561782674bb34431a57220b8c2e76631
Complete output (31 lines):
Traceback (most recent call last):
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 126, 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/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 280, in <module>
main()
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 263, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 130, in prepare_metadata_for_build_wheel
return _get_wheel_metadata_from_wheel(backend, metadata_directory,
File "/Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 159, in _get_wheel_metadata_from_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-bdif8fjh/overlay/lib/python3.8/site-packages/sipbuild/api.py", line 51, in build_wheel
project = AbstractProject.bootstrap('pep517')
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-bdif8fjh/overlay/lib/python3.8/site-packages/sipbuild/abstract_project.py", line 83, in bootstrap
project.setup(pyproject, tool, tool_description)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-bdif8fjh/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 479, in setup
self.apply_user_defaults(tool)
File "project.py", line 62, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-bdif8fjh/overlay/lib/python3.8/site-packages/pyqtbuild/project.py", line 70, in apply_user_defaults
super().apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-bdif8fjh/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 225, in apply_user_defaults
self.builder.apply_user_defaults(tool)
File "/private/var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/pip-build-env-bdif8fjh/overlay/lib/python3.8/site-packages/pyqtbuild/builder.py", line 66, in apply_user_defaults
raise PyProjectOptionException('qmake',
sipbuild.pyproject.PyProjectOptionException
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/3a/fb/eb51731f2dc7c22d8e1a63ba88fb702727b324c6352183a32f27f73b8116/PyQt5-5.14.1.tar.gz#sha256=2f230f2dbd767099de7a0cb915abdf0cbc3256a0b5bb910eb09b99117db7a65b (from https://pypi.org/simple/pyqt5/) (requires-python:>=3.5). Command errored out with exit status 1: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 /Library/Python/3.8/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /var/folders/kk/ck6hb36n5z1373zlhm46l3m80000gn/T/tmpgyk62cud Check the logs for full command output.
Using cached PyQt5-5.14.0.tar.gz (3.2 MB)
ERROR: pyqt5 from https://files.pythonhosted.org/packages/7c/5b/e760ec4f868cb77cee45b4554bf15d3fe6972176e89c4e3faac941213694/PyQt5-5.14.0.tar.gz#sha256=0145a6b7de15756366decb736c349a0cb510d706c83fda5b8cd9e0557bc1da72 has a pyproject.toml file that does not comply with PEP 518: 'build-system.requires' contains an invalid requirement: 'sip >=5.0.1 <6'
jett#jmac ~ %
Are you using an M1 Mac? If so, this worked for me: How can i run pyqt5 on my mac with M1chip
In case that page gets removed and someone needs this:
Right click the Terminal application in Finder, click duplicate.
Rename one of them so you know which is which.
Right click the renamed one, and click "Get Info". Check the option "Open using Rosetta"
Open the Rosetta version, create a virtual Python environment. /usr/bin/python3 -m venv env
Activate the environment. source env/bin/activate
Upgrade pip pip install --upgrade pip
Install PyQt5 pip install PyQt5
This worked for me on an M1 Air running Big Sur, I can't say if it helps on Intel Macs.
answer from Mike Simone worked for me except for step 7, which failed using pyqt5, but was successful using pyqt6.
pyqt6 installed for ARM, as seen from the output below.
In code simply change your imports to PyQt6. There are some minor code differences.
(venv) username#MacPunch pushbutton % pip install PyQt6
Collecting PyQt6
Downloading PyQt6-6.4.0-cp37-abi3-macosx_10_14_universal2.whl (11.6 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 11.6/11.6 MB 3.2 MB/s eta 0:00:00
Collecting PyQt6-Qt6>=6.4.0
Downloading PyQt6_Qt6-6.4.1-py3-none-macosx_11_0_arm64.whl (38.0 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 38.0/38.0 MB 2.5 MB/s eta 0:00:00
Collecting PyQt6-sip<14,>=13.4
Downloading PyQt6_sip-13.4.0.tar.gz (111 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 111.2/111.2 kB 2.2 MB/s eta 0:00:00
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... done
Building wheels for collected packages: PyQt6-sip
Building wheel for PyQt6-sip (pyproject.toml) ... done
Created wheel for PyQt6-sip: filename=PyQt6_sip-13.4.0-cp38-cp38-macosx_10_14_arm64.whl size=132021 sha256=871d16c4c852b49b9d4859ece2d516a4e650fe10a0024f9bf7105773b5ad0be9
Stored in directory: /Users/username/Library/Caches/pip/wheels/98/43/59/58c7e4bf0439947e465446a8948e84910729052c76131272e8
Successfully built PyQt6-sip
Installing collected packages: PyQt6-Qt6, PyQt6-sip, PyQt6
Successfully installed PyQt6-6.4.0 PyQt6-Qt6-6.4.1 PyQt6-sip-13.4.0
(venv) username#MacPunch pushbutton %
The chosen answer has pretty much says it all, and it solved mine too. Just a side note, the virtual environment must be created from the system python located /usr/bin/python3, other pythons won't work.
I have tried to install the bls-lib library but this error kept showing, can anyone help me what's wrong with it? I even tried to install the petlib library because I thought that it will solve the problem but I got an almost simmilar error.
(venv) C:\Users\admin\PycharmProjects\Testing\venv>pip install bls-lib
Collecting bls-lib
Using cached bls_lib-1.0.1-py3-none-any.whl (16 kB)
Collecting bplib
Using cached bplib-0.0.6.tar.gz (40 kB)
ERROR: Command errored out with exit status 1:
command: 'c:\users\admin\pycharmprojects\testing\venv\scripts\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\admin\\AppData\\Lo
cal\\Temp\\pip-install-bys_0pq0\\bplib\\setup.py'"'"'; __file__='"'"'C:\\Users\\admin\\AppData\\Local\\Temp\\pip-install-bys_0pq0\\bplib\\setup.py'"'"';f=getattr(tok
enize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-ba
se 'C:\Users\admin\AppData\Local\Temp\pip-pip-egg-info-b9zc7inm'
cwd: C:\Users\admin\AppData\Local\Temp\pip-install-bys_0pq0\bplib\
Complete output (63 lines):
ERROR: Command errored out with exit status 1:
command: 'c:\users\admin\pycharmprojects\testing\venv\scripts\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\admin\\AppData
\\Local\\Temp\\pip-wheel-p1rs96jl\\petlib\\setup.py'"'"'; __file__='"'"'C:\\Users\\admin\\AppData\\Local\\Temp\\pip-wheel-p1rs96jl\\petlib\\setup.py'"'"';f=getattr(t
okenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-
base 'C:\Users\admin\AppData\Local\Temp\pip-pip-egg-info-iyyhus4_'
cwd: C:\Users\admin\AppData\Local\Temp\pip-wheel-p1rs96jl\petlib\
Complete output (27 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\admin\AppData\Local\Temp\pip-wheel-p1rs96jl\petlib\setup.py", line 7, in <module>
setup(name='petlib',
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\setuptools\__init__.py", line 153, in setup
return distutils.core.setup(**attrs)
File "C:\Users\admin\AppData\Local\Programs\Python\Python39\lib\distutils\core.py", line 108, in setup
_setup_distribution = dist = klass(attrs)
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\setuptools\dist.py", line 423, in __init__
_Distribution.__init__(self, {
File "C:\Users\admin\AppData\Local\Programs\Python\Python39\lib\distutils\dist.py", line 292, in __init__
self.finalize_options()
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\setuptools\dist.py", line 695, in finalize_options
ep(self)
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\setuptools\dist.py", line 702, in _finalize_setup_keywords
ep.load()(self, ep.name, value)
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\cffi\setuptools_ext.py", line 219, in cffi_modules
add_cffi_module(dist, cffi_module)
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\cffi\setuptools_ext.py", line 49, in add_cffi_module
execfile(build_file_name, mod_vars)
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\cffi\setuptools_ext.py", line 25, in execfile
exec(code, glob, glob)
File "petlib/compile.py", line 34, in <module>
openssl_conf = os.environ["OPENSSL_CONF"]
File "C:\Users\admin\AppData\Local\Programs\Python\Python39\lib\os.py", line 679, in __getitem__
raise KeyError(key) from None
KeyError: 'OPENSSL_CONF'
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Traceback (most recent call last):
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\setuptools\installer.py", line 126, in fetch_build_egg
subprocess.check_call(cmd)
File "C:\Users\admin\AppData\Local\Programs\Python\Python39\lib\subprocess.py", line 373, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['c:\\users\\admin\\pycharmprojects\\testing\\venv\\scripts\\python.exe', '-m', 'pip', '--disable-pip-version-check', 'wh
eel', '--no-deps', '-w', 'C:\\Users\\admin\\AppData\\Local\\Temp\\tmpu5quqolr', '--quiet', 'petlib>=0.0.45']' returned non-zero exit status 1.
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\admin\AppData\Local\Temp\pip-install-bys_0pq0\bplib\setup.py", line 7, in <module>
setup(name='bplib',
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\setuptools\__init__.py", line 152, in setup
_install_setup_requires(attrs)
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\setuptools\__init__.py", line 147, in _install_setup_requires
dist.fetch_build_eggs(dist.setup_requires)
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\setuptools\dist.py", line 673, in fetch_build_eggs
resolved_dists = pkg_resources.working_set.resolve(
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\pkg_resources\__init__.py", line 764, in resolve
dist = best[req.key] = env.best_match(
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\pkg_resources\__init__.py", line 1049, in best_match
return self.obtain(req, installer)
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\pkg_resources\__init__.py", line 1061, in obtain
return installer(requirement)
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\setuptools\dist.py", line 732, in fetch_build_egg
return fetch_build_egg(self, req)
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\setuptools\installer.py", line 128, in fetch_build_egg
raise DistutilsError(str(e)) from e
distutils.errors.DistutilsError: Command '['c:\\users\\admin\\pycharmprojects\\testing\\venv\\scripts\\python.exe', '-m', 'pip', '--disable-pip-version-check', '
wheel', '--no-deps', '-w', 'C:\\Users\\admin\\AppData\\Local\\Temp\\tmpu5quqolr', '--quiet', 'petlib>=0.0.45']' returned non-zero exit status 1.
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
This is the error of installing the petlib library:
(venv) C:\Users\admin\PycharmProjects\Testing>pip install petlib
Collecting petlib
Using cached petlib-0.0.45.tar.gz (245 kB)
ERROR: Command errored out with exit status 1:
command: 'c:\users\admin\pycharmprojects\testing\venv\scripts\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\admin\\AppData\\Lo
cal\\Temp\\pip-install-yp8f_epx\\petlib\\setup.py'"'"'; __file__='"'"'C:\\Users\\admin\\AppData\\Local\\Temp\\pip-install-yp8f_epx\\petlib\\setup.py'"'"';f=getattr(t
okenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-
base 'C:\Users\admin\AppData\Local\Temp\pip-pip-egg-info-gyl6jkzc'
cwd: C:\Users\admin\AppData\Local\Temp\pip-install-yp8f_epx\petlib\
Complete output (27 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\admin\AppData\Local\Temp\pip-install-yp8f_epx\petlib\setup.py", line 7, in <module>
setup(name='petlib',
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\setuptools\__init__.py", line 153, in setup
return distutils.core.setup(**attrs)
File "C:\Users\admin\AppData\Local\Programs\Python\Python39\lib\distutils\core.py", line 108, in setup
_setup_distribution = dist = klass(attrs)
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\setuptools\dist.py", line 423, in __init__
_Distribution.__init__(self, {
File "C:\Users\admin\AppData\Local\Programs\Python\Python39\lib\distutils\dist.py", line 292, in __init__
self.finalize_options()
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\setuptools\dist.py", line 695, in finalize_options
ep(self)
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\setuptools\dist.py", line 702, in _finalize_setup_keywords
ep.load()(self, ep.name, value)
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\cffi\setuptools_ext.py", line 219, in cffi_modules
add_cffi_module(dist, cffi_module)
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\cffi\setuptools_ext.py", line 49, in add_cffi_module
execfile(build_file_name, mod_vars)
File "c:\users\admin\pycharmprojects\testing\venv\lib\site-packages\cffi\setuptools_ext.py", line 25, in execfile
exec(code, glob, glob)
File "petlib/compile.py", line 34, in <module>
openssl_conf = os.environ["OPENSSL_CONF"]
File "C:\Users\admin\AppData\Local\Programs\Python\Python39\lib\os.py", line 679, in __getitem__
raise KeyError(key) from None
KeyError: 'OPENSSL_CONF'
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Every time I am installing a package for my python3 via pip3 it downloads or browses cache and returns a similar error.
I've already tried sudo -H flag but same results.
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-0l02yx4z/numba/setup.py'"'"'; __file__='"'"'/tmp/pip-install-0l02yx4z/numba/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-install-0l02yx4z/numba/pip-egg-info
cwd: /tmp/pip-install-0l02yx4z/numba/
Complete output (36 lines):
Traceback (most recent call last):
File "/usr/local/lib/python3.6/dist-packages/pkg_resources/__init__.py", line 2857, in get_entry_map
ep_map = self._ep_map
File "/usr/local/lib/python3.6/dist-packages/pkg_resources/__init__.py", line 2815, in __getattr__
raise AttributeError(attr)
AttributeError: _ep_map
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-0l02yx4z/numba/setup.py", line 365, in <module>
setup(**metadata)
File "/usr/local/lib/python3.6/dist-packages/setuptools/__init__.py", line 144, in setup
_install_setup_requires(attrs)
File "/usr/local/lib/python3.6/dist-packages/setuptools/__init__.py", line 133, in _install_setup_requires
(k, v) for k, v in attrs.items()
File "/usr/local/lib/python3.6/dist-packages/setuptools/dist.py", line 444, in __init__
for ep in pkg_resources.iter_entry_points('distutils.setup_keywords'):
File "/usr/local/lib/python3.6/dist-packages/pkg_resources/__init__.py", line 656, in <genexpr>
for entry in dist.get_entry_map(group).values()
File "/usr/local/lib/python3.6/dist-packages/pkg_resources/__init__.py", line 2860, in get_entry_map
self._get_metadata('entry_points.txt'), self
File "/usr/local/lib/python3.6/dist-packages/pkg_resources/__init__.py", line 2527, in parse_map
for group, lines in data:
File "/usr/local/lib/python3.6/dist-packages/pkg_resources/__init__.py", line 3198, in split_sections
for line in yield_lines(s):
File "/usr/local/lib/python3.6/dist-packages/pkg_resources/__init__.py", line 2387, in yield_lines
for ss in strs:
File "/usr/local/lib/python3.6/dist-packages/pkg_resources/__init__.py", line 2767, in _get_metadata
for line in self.get_metadata_lines(name):
File "/usr/local/lib/python3.6/dist-packages/pkg_resources/__init__.py", line 1432, in get_metadata_lines
return yield_lines(self.get_metadata(name))
File "/usr/local/lib/python3.6/dist-packages/pkg_resources/__init__.py", line 1424, in get_metadata
return value.decode('utf-8')
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xff in position 0: invalid start byte in entry_points.txt file at path: /usr/local/lib/python3.6/dist-packages/tensorflow_gpu-1.14.0+nv19.9.dist-info/entry_points.txt
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
if by any change you are using a Windows machine, you could probably enable utf-8 in the administrative regional settings:
Enable utf-8 in Regional Settings
this resolved this issue for me.
I'm trying to install twython, but keep getting errors.
First attempt:
pi#raspberrypi ~/twython $ sudo pip-3.2 install twython
Running setup.py egg_info for package requests
Traceback (most recent call last):
File "<string>", line 14, in <module>
File "/home/pi/twython/build/requests/setup.py", line 52, in <module>
exec(f.read(), about)
File "<string>", line 14
__cake__ = u'\u2728 \U0001f370 \u2728'
^
SyntaxError: invalid syntax
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 14, in <module>
File "/home/pi/twython/build/requests/setup.py", line 52, in <module>
exec(f.read(), about)
File "<string>", line 14
__cake__ = u'\u2728 \U0001f370 \u2728'
^
SyntaxError: invalid syntax
----------------------------------------
Command python setup.py egg_info failed with error code 1 in /home/pi/twython/build/requests
Next I searched on the last line of the error and followed some suggestions that said to make sure setuptools and ez_install were installed and up to date, but that didn't help.
Then I followed the backup instructions on ReadtheDocs that said to try to install it this way:
git clone git://github.com/ryanmcgrath/twython.git
cd twython
sudo python3 setup.py install
but it failed again:
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 640, in install_item
self.process_distribution(spec, dist, deps)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 692, in process_distribution
[requirement], self.local_index, self.easy_install
File "/usr/lib/python3/dist-packages/pkg_resources.py", line 576, in resolve
dist = best[req.key] = env.best_match(req, self, installer)
File "/usr/lib/python3/dist-packages/pkg_resources.py", line 822, in best_match
return self.obtain(req, installer) # try and download/install
File "/usr/lib/python3/dist-packages/pkg_resources.py", line 834, in obtain
return installer(requirement)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 608, in easy_install
return self.install_item(spec, dist.location, tmpdir, deps)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 638, in install_item
dists = self.install_eggs(spec, download, tmpdir)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 828, in install_eggs
return self.build_and_install(setup_script, setup_base)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 1105, in build_and_install
self.run_setup(setup_script, setup_base, args)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 1094, in run_setup
run_setup(setup_script, args)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 31, in run_setup
lambda: exec(compile(open(
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 73, in run
return func()
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 34, in <lambda>
{'__file__':setup_script, '__name__':'__main__'})
File "setup.py", line 52, in <module>
Error in atexit._run_exitfuncs:
TypeError: 'NoneType' object is not callable
It turns out that Twython cannot work with Python v3.2 because it depends on the requests module which apparently is not supported in Python 3.2.
One of the developers of Twython just explained this to me on Twitter.