Cannot install python-poppler - python

I am trying to install python-poppler by using pip install python-poppler. I am using a Jupyter Notebook on Windows.
When I run this, I receive the following errors:
RuntimeError: CMake must be installed to build the following extensions: poppler.cpp.modules
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for python-poppler
error: subprocess-exited-with-error
RuntimeError: CMake must be installed to build the following extensions: poppler.cpp.modules
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure
I have Cmake installed. Any ideas on how to fix this?

Related

Snowflake-connector-python fails to install. Returns "ModuleNotFoundError: No module named 'cmake'"

I'm trying to install snowflake-connector-python using pip, but it's giving me this error stack trace:
copying pyarrow/tests/parquet/test_metadata.py -> build/lib.macosx-10.9-universal2-cpython-311/pyarrow/tests/parquet
copying pyarrow/tests/parquet/test_pandas.py -> build/lib.macosx-10.9-universal2-cpython-311/pyarrow/tests/parquet
copying pyarrow/tests/parquet/test_parquet_file.py -> build/lib.macosx-10.9-universal2-cpython-311/pyarrow/tests/parquet
copying pyarrow/tests/parquet/test_parquet_writer.py -> build/lib.macosx-10.9-universal2-cpython-311/pyarrow/tests/parquet
running build_ext
creating /private/var/folders/4c/xj1m5wts0xx46bbh5qhhhg4m0000gq/T/pip-install-v4ysgr2_/pyarrow_ae70c3da10594e6eb24b27149ad7d95d/build/temp.macosx-10.9-universal2-cpython-311
-- Running cmake for pyarrow
cmake -DPYTHON_EXECUTABLE=/Users/gree030/Workspace/projectName/venv/bin/python -DPython3_EXECUTABLE=/Users/gree030/Workspace/projectName/venv/bin/python "" -DPYARROW_BUILD_CUDA=off -DPYARROW_BUILD_FLIGHT=off -DPYARROW_BUILD_GANDIVA=off -DPYARROW_BUILD_DATASET=off -DPYARROW_BUILD_ORC=off -DPYARROW_BUILD_PARQUET=off -DPYARROW_BUILD_PARQUET_ENCRYPTION=off -DPYARROW_BUILD_PLASMA=off -DPYARROW_BUILD_S3=off -DPYARROW_BUILD_HDFS=off -DPYARROW_USE_TENSORFLOW=off -DPYARROW_BUNDLE_ARROW_CPP=off -DPYARROW_BUNDLE_BOOST=off -DPYARROW_GENERATE_COVERAGE=off -DPYARROW_BOOST_USE_SHARED=on -DPYARROW_PARQUET_USE_SHARED=on -DCMAKE_BUILD_TYPE=release /private/var/folders/4c/xj1m5wts0xx46bbh5qhhhg4m0000gq/T/pip-install-v4ysgr2_/pyarrow_ae70c3da10594e6eb24b27149ad7d95d
error: command 'cmake' failed: No such file or directory
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for pyarrow
Failed to build pyarrow
ERROR: Could not build wheels for pyarrow, which is required to install pyproject.toml-based projects
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error
× pip subprocess to install build dependencies did not run successfully.
│ exit code: 1
╰─> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
Here are my environments:
Python version: 3.11.1
pip version: 22.3.1
I tried installing and updating cmake but it still gave me this error:
copying pyarrow/tests/parquet/test_pandas.py -> build/lib.macosx-10.9-universal2-cpython-311/pyarrow/tests/parquet
copying pyarrow/tests/parquet/test_parquet_file.py -> build/lib.macosx-10.9-universal2-cpython-311/pyarrow/tests/parquet
copying pyarrow/tests/parquet/test_parquet_writer.py -> build/lib.macosx-10.9-universal2-cpython-311/pyarrow/tests/parquet
running build_ext
creating /private/var/folders/4c/xj1m5wts0xx46bbh5qhhhg4m0000gq/T/pip-install-ejkkok_0/pyarrow_e560da15c45d4feeb95b2060af382048/build/temp.macosx-10.9-universal2-cpython-311
-- Running cmake for pyarrow
cmake -DPYTHON_EXECUTABLE=/Users/gree030/Workspace/projectName/venv/bin/python -DPython3_EXECUTABLE=/Users/gree030/Workspace/projectName/venv/bin/python "" -DPYARROW_BUILD_CUDA=off -DPYARROW_BUILD_FLIGHT=off -DPYARROW_BUILD_GANDIVA=off -DPYARROW_BUILD_DATASET=off -DPYARROW_BUILD_ORC=off -DPYARROW_BUILD_PARQUET=off -DPYARROW_BUILD_PARQUET_ENCRYPTION=off -DPYARROW_BUILD_PLASMA=off -DPYARROW_BUILD_S3=off -DPYARROW_BUILD_HDFS=off -DPYARROW_USE_TENSORFLOW=off -DPYARROW_BUNDLE_ARROW_CPP=off -DPYARROW_BUNDLE_BOOST=off -DPYARROW_GENERATE_COVERAGE=off -DPYARROW_BOOST_USE_SHARED=on -DPYARROW_PARQUET_USE_SHARED=on -DCMAKE_BUILD_TYPE=release /private/var/folders/4c/xj1m5wts0xx46bbh5qhhhg4m0000gq/T/pip-install-ejkkok_0/pyarrow_e560da15c45d4feeb95b2060af382048
Traceback (most recent call last):
File "/Users/gree030/Workspace/projectName/venv/bin/cmake", line 5, in <module>
from cmake import cmake
ModuleNotFoundError: No module named 'cmake'
error: command '/Users/gree030/Workspace/projectName/venv/bin/cmake' failed with exit code 1
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for pyarrow
Failed to build pyarrow
ERROR: Could not build wheels for pyarrow, which is required to install pyproject.toml-based projects
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error
× pip subprocess to install build dependencies did not run successfully.
│ exit code: 1
╰─> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
I also followed the documentation here and dependency installment guide here on how to install the connector and downloaded the dependent libraries using:
pip install -r https://raw.githubusercontent.com/snowflakedb/snowflake-connector-python/main/tested_requirements/requirements_311.reqs
given that my python version is 3.11.0.
It turns out that the build dependencies were causing the problem. One of the dependencies pyarrow seems to be triggering the error when using python 3.11 at the time of this writing. Downgrading to python version 3.9.16 solved the issue with installing snowflake-connector-python.

Error while installing apache superset Could not build wheels for numpy, which is required to install pyproject.toml-based projects [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for numpy
Failed to build numpy
ERROR: Could not build wheels for numpy, which is required to install pyproject.toml-based projects
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error
× pip subprocess to install build dependencies did not run successfully.
│ exit code: 1
╰─> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
pip install apache-superset

Error while trying to install odoo15 requirements.txt on M1

I am trying to install the requirements for odoo15 on my MBP M1 Pro running MacOS Ventura 13.0 in my virtual environment running python 3.10.8
but I keep getting the following error:
build/temp.macosx-12-arm64-cpython-310/_openssl.c:575:10: fatal error: 'openssl/opensslv.h' file not found
#include <openssl/opensslv.h>
^~~~~~~~~~~~~~~~~~~~
1 error generated.
error: command '/usr/bin/clang' failed with exit code 1
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for cryptography
Building wheel for psycopg2 (setup.py) ... error
error: subprocess-exited-with-error
...
ld: warning: directory not found for option '-L/usr/local/opt/openssl/lib'
ld: library not found for -lssl
clang: error: linker command failed with exit code 1 (use -v to see invocation)
error: command '/usr/bin/clang' failed with exit code 1
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for psycopg2
Running setup.py clean for psycopg2
...
Failed to build cryptography psycopg2
ERROR: Could not build wheels for cryptography, which is required to install pyproject.toml-based projects
Now, I have already spent a lot of time researching and it seems that openssl might be the problem here
I have already install openssl via brew, it is running the newest version, as suggested in this GitHub issue
I have installed the newest version of pip as suggested in this StackOverflow post
Edit: I have now also tried setting these flags as suggested in this StackOverflow post:
export LDFLAGS="-L/opt/homebrew/opt/openssl#1.1/lib"
export CPPFLAGS="-I/opt/homebrew/opt/openssl#1.1/include"
I have also retried everything in another venv using Python version 3.8

note: This error originates from a subprocess and is likely not a problem with pip

while downloading pip install vidstream
I am using Python 3.10.1, win 10 pro and the lastest version of VS c++
I faced this problem :
src/_portaudiomodule.c: note: б¬. ЇаҐ¤л¤г饥 ®ЇаҐ¤Ґ«Ґ­ЁҐ "MS_WIN64"
src/_portaudiomodule.c(29): fatal error C1083: ЌҐ г¤ Ґвбп ®вЄалвм д ©« ўЄ«о祭ЁҐ: portaudio.h: No such file or directory,
error: command 'C:\\Program Files\\Microsoft Visual Studio\\2022\\Community\\VC\\Tools\\MSVC\\14.31.31103\\bin\\HostX86\\x64\\cl.exe' failed with exit code 2
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure
Encountered error while trying to install package.
pyaudio
note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure. ```
what should I do?

Can't install scikit-learn on mac

I am trying to install scikit-learn and scipy packages in Python. I've already installed NumPy and Pandas successfully. Then I used following command:
pip install scikit-learn
and I received following error:
File "/private/tmp/pip-build-env-w7wmv28v/overlay/lib/python3.9/site-packages/wheel/bdist_wheel.py", line 278, in get_tag
assert tag in supported_tags, "would build wheel with unsupported tag {}".format(tag)
AssertionError: would build wheel with unsupported tag ('cp39', 'cp39', 'macosx_11_0_universal2')
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for numpy
Failed to build numpy
ERROR: Could not build wheels for numpy, which is required to install pyproject.toml-based projects
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error
× pip subprocess to install build dependencies did not run successfully.
│ exit code: 1
╰─> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error
× pip subprocess to install build dependencies did not run successfully.
│ exit code: 1
╰─> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
I am using python 3.9.10, and a mac computer. What should I do?
Have you tried this?:
pip install sklearn

Categories