Open yjz1234 opened 4 years ago
Same issue here! First time installing this it stopped on petlib
. Second try and so on, it has the same error as yours. Then I thought maybe petlib
is the culprit. And I tried to install petlib
alone, and I got OPENSSL_CONF error too! Maybe this might lead to something?
Yes,that's because openssl is incompatible with petlib. There is issue :https://github.com/gdanezis/petlib/issues/23.
It is still trying to use petlib, whether it's from PyPI or directly cloning this repository. Are there still files that use it? I got this error:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\Rifqi\AppData\Local\Temp\pip-wheel-oq054npq\petlib\setup.py", line 40, in <module>
zip_safe=False,
File "e:\computer language\python 3.7.2\lib\site-packages\setuptools\__init__.py", line 145, in setup
return distutils.core.setup(**attrs)
File "e:\computer language\python 3.7.2\lib\distutils\core.py", line 108, in setup
_setup_distribution = dist = klass(attrs)
File "e:\computer language\python 3.7.2\lib\site-packages\setuptools\dist.py", line 448, in __init__
k: v for k, v in attrs.items()
File "e:\computer language\python 3.7.2\lib\distutils\dist.py", line 292, in __init__
self.finalize_options()
File "e:\computer language\python 3.7.2\lib\site-packages\setuptools\dist.py", line 740, in finalize_options
ep.load()(self)
File "e:\computer language\python 3.7.2\lib\site-packages\setuptools\dist.py", line 747, in _finalize_setup_keywords
ep.load()(self, ep.name, value)
File "e:\computer language\python 3.7.2\lib\site-packages\cffi\setuptools_ext.py", line 217, in cffi_modules
add_cffi_module(dist, cffi_module)
File "e:\computer language\python 3.7.2\lib\site-packages\cffi\setuptools_ext.py", line 49, in add_cffi_module
execfile(build_file_name, mod_vars)
File "e:\computer language\python 3.7.2\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 "e:\computer language\python 3.7.2\lib\os.py", line 678, in __getitem__
raise KeyError(key) from None
KeyError: 'OPENSSL_CONF'
Near the end there is a "petlib" used.
That's a bug on windows's openssl, you can look it in https://github.com/gdanezis/petlib/issues/23
Can someone re-do & update the install guide? Which OpenSSL binary edition v? From where as the link is dead? Where should it be placed, which directory? After executing the command vcvars32.bat or vcvarsx86_amd64.bat, the path should be correctly configured by? Is the dependency crypto, pip crypto? pip pycrypto? a library in OpenSSL?
I have tried following the guide,
On Windows, install 32 bit or 64 bit OpenSSL binary edition matching your Python installation. (64 bit) Ensure libeay32.dll is on the system PATH (https://www.openssl.org/related/binaries.html). THIS LINK NO LONGER WORKS Configure the path variables of Microsoft VS compilers for 32 bit or 64 bit architectures, by executing the command vcvars32.bat or vcvarsx86_amd64.bat.
I found the binaries here, https://wiki.openssl.org/index.php/Binaries First I placed them separately in OS Then ran the vcvarsx86_amd64.bat and set the PATH, when this didn't work I tried placing them in python, pip, OpenSSL... and setting the path both via vcvarsx86_amd64.bat & environments.
However every time I run pip install petlib it fails with
_DeprecatedInstaller: setuptools.installer and fetch_build_eggs are deprecated.
Requirements should be satisfied by a PEP 517 installer.
If you are using pip, you can try pip install --use-pep517
.
OSError: ctypes.util.find_library() did not manage to locate a library called 'crypto'
However, pip install --use-pep517 petlib, also fails! Collecting petlib Using cached petlib-0.0.45.tar.gz (245 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Installing backend dependencies ... done Preparing metadata (pyproject.toml) ... error error: subprocess-exited-with-error
× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [50 lines of output]
Traceback (most recent call last):
File "C:\Users\k_alex\AppData\Local\Programs\Python\Python311\Lib\site-packages\pip_vendor\pyproject_hooks_in_process_in_process.py", line 353, in
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.
When I am installing in my pc with win 10 ,it's error : ` Complete output from command python setup.py egg_info: Traceback (most recent call last): File "d:\python3\lib\site-packages\setuptools\sandbox.py", line 154, in save_modules yield saved File "d:\python3\lib\site-packages\setuptools\sandbox.py", line 195, in setup_context yield File "d:\python3\lib\site-packages\setuptools\sandbox.py", line 250, in run_setup _execfile(setup_script, ns) File "d:\python3\lib\site-packages\setuptools\sandbox.py", line 45, in _execfile exec(code, globals, locals) File "C:\Users\12711\AppData\Local\Temp\easy_install-lzkw1izd\petlib-0.0.45\setup.py", line 40, in
],
File "d:\python3\lib\site-packages\setuptools__init.py", line 143, in setup
return distutils.core.setup(**attrs)
File "d:\python3\lib\distutils\core.py", line 108, in setup
_setup_distribution = dist = klass(attrs)
File "d:\python3\lib\site-packages\setuptools\dist.py", line 442, in init
k: v for k, v in attrs.items()
File "d:\python3\lib\distutils\dist.py", line 281, in init
self.finalize_options()
File "d:\python3\lib\site-packages\setuptools\dist.py", line 601, in finalize_options
ep.load()(self, ep.name, value)
File "d:\python3\lib\site-packages\cffi\setuptools_ext.py", line 217, in cffi_modules
add_cffi_module(dist, cffi_module)
File "d:\python3\lib\site-packages\cffi\setuptools_ext.py", line 49, in add_cffi_module
execfile(build_file_name, mod_vars)
File "d:\python3\lib\site-packages\cffi\setuptools_ext.py", line 25, in execfile
exec(code, glob, glob)
File "petlib/compile.py", line 34, in
File "d:\python3\lib\os.py", line 669, in getitem__
raise KeyError(key) from None
KeyError: 'OPENSSL_CONF'
Command "python setup.py egg_info" failed with error code 1 in C:\Users\12711\AppData\Local\Temp\pip-install-575rjrxd\bplib`