Comments (3)
@semolas, @piiq - I'd suggest doing a pip install --upgrade pip
to upgrade to the latest pip
first (which is capable of building osqp
in a containerized environment with cmake
automatically installed in it). python setup.py install
is not the recommended way going forward. Once you do this, then try pip install osqp==0.6.2.post5
or pip install .
(from inside the repository cloned using git clone --recurse-submodules git@...
from osqp-python.
Experiencing the same error when cmake is installed from pip
root@36d9bc0932ad:/# cmake --version
cmake version 3.24.3
CMake suite maintained and supported by Kitware (kitware.com/cmake).
Tried to install in a python:3.9 docker container (architecture:arm64) and in an python 3.9 macOS arm64 conda environment
It seems that the installation process has problems specifically with cmake installed from pip as it works correctly on when cmake is installed from brew (macos) or apt (debian/ubuntu)
@vineetbansal do you think this can be mitigated by providing a full path to cmake in the call
call in the setup.py? Let me know if I can assist solving this issue
from osqp-python.
I have this problem with osqp==0.6.3
too. Here is my env:
MacOS Ventura 13.3
pip==23.2.1
setuptools==68.1.2
wheel==0.41.1
cmake==(I tried from 3.25.0 to the latest version)
I run it in a Python virtual env. I install cmake
first, and then osqp
. I don't install them in a same requirements.txt
.
Before installing osqp
, I run which cmake
and see it is available here:
/Users/someone/git/an-application/venv/bin/cmake
When installing osqp
, I got this error:
Collecting osqp==0.6.3
Downloading osqp-0.6.3.tar.gz (228 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 228.4/228.4 kB 2.7 MB/s eta 0:00:00
Installing build dependencies ... error
error: subprocess-exited-with-error
× pip subprocess to install build dependencies did not run successfully.
│ exit code: 1
╰─> [111 lines of output]
Collecting oldest-supported-numpy
Obtaining dependency information for oldest-supported-numpy from https://files.pythonhosted.org/packages/94/9a/756fef9346e5ca2289cb70d73990b4c9f25446a885c1186cfb93a85e7da0/oldest_supported_numpy-2023.8.3-py3-none-any.whl.metadata
Using cached oldest_supported_numpy-2023.8.3-py3-none-any.whl.metadata (9.5 kB)
Collecting setuptools>=40.8.0
Obtaining dependency information for setuptools>=40.8.0 from https://files.pythonhosted.org/packages/4f/ab/0bcfebdfc3bfa8554b2b2c97a555569c4c1ebc74ea288741ea8326c51906/setuptools-68.1.2-py3-none-any.whl.metadata
Using cached setuptools-68.1.2-py3-none-any.whl.metadata (6.2 kB)
Collecting wheel
Obtaining dependency information for wheel from https://files.pythonhosted.org/packages/28/f5/6955d7b3a5d71ce6bac104f9cf98c1b0513ad656cdaca8ea7d579196f771/wheel-0.41.1-py3-none-any.whl.metadata
Using cached wheel-0.41.1-py3-none-any.whl.metadata (2.2 kB)
Collecting setuptools_scm>=6.2
Using cached setuptools_scm-7.1.0-py3-none-any.whl (43 kB)
Collecting qdldl
Using cached qdldl-0.1.7.post0.tar.gz (70 kB)
Installing build dependencies: started
Installing build dependencies: finished with status 'done'
Getting requirements to build wheel: started
Getting requirements to build wheel: finished with status 'done'
Installing backend dependencies: started
Installing backend dependencies: finished with status 'done'
Preparing metadata (pyproject.toml): started
Preparing metadata (pyproject.toml): finished with status 'done'
Collecting numpy==1.21.6 (from oldest-supported-numpy)
Using cached numpy-1.21.6-cp310-cp310-macosx_11_0_arm64.whl (12.4 MB)
Collecting packaging>=20.0 (from setuptools_scm>=6.2)
Using cached packaging-23.1-py3-none-any.whl (48 kB)
Collecting typing-extensions (from setuptools_scm>=6.2)
Obtaining dependency information for typing-extensions from https://files.pythonhosted.org/packages/ec/6b/63cc3df74987c36fe26157ee12e09e8f9db4de771e0f3404263117e75b95/typing_extensions-4.7.1-py3-none-any.whl.metadata
Using cached typing_extensions-4.7.1-py3-none-any.whl.metadata (3.1 kB)
Collecting tomli>=1.0.0 (from setuptools_scm>=6.2)
Using cached tomli-2.0.1-py3-none-any.whl (12 kB)
Collecting scipy>=0.13.2 (from qdldl)
Obtaining dependency information for scipy>=0.13.2 from https://files.pythonhosted.org/packages/63/b9/0344b60e7c577eb637785841222fde8ef7928ec4797be1a34ca39bfe31dc/scipy-1.11.2-cp310-cp310-macosx_12_0_arm64.whl.metadata
Using cached scipy-1.11.2-cp310-cp310-macosx_12_0_arm64.whl.metadata (100 kB)
Using cached oldest_supported_numpy-2023.8.3-py3-none-any.whl (4.8 kB)
Using cached setuptools-68.1.2-py3-none-any.whl (805 kB)
Using cached wheel-0.41.1-py3-none-any.whl (64 kB)
Using cached scipy-1.11.2-cp310-cp310-macosx_12_0_arm64.whl (29.6 MB)
Using cached typing_extensions-4.7.1-py3-none-any.whl (33 kB)
Building wheels for collected packages: qdldl
Building wheel for qdldl (pyproject.toml): started
Building wheel for qdldl (pyproject.toml): finished with status 'error'
error: subprocess-exited-with-error
× Building wheel for qdldl (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [59 lines of output]
running bdist_wheel
running build
running build_ext
Traceback (most recent call last):
File "/Users/someone/git/an-application/venv/bin/cmake", line 5, in <module>
from cmake import cmake
ModuleNotFoundError: No module named 'cmake'
Traceback (most recent call last):
File "/Users/someone/git/an-application/venv/lib/python3.10/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
main()
File "/Users/someone/git/an-application/venv/lib/python3.10/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "/Users/someone/git/an-application/venv/lib/python3.10/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 251, in build_wheel
return _build_backend().build_wheel(wheel_directory, config_settings,
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 434, in build_wheel
return self._build_with_temp_dir(
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 419, in _build_with_temp_dir
self.run_setup()
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 341, in run_setup
exec(code, locals())
File "<string>", line 113, in <module>
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/__init__.py", line 107, in setup
return distutils.core.setup(**attrs)
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/_distutils/core.py", line 185, in setup
return run_commands(dist)
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/_distutils/core.py", line 201, in run_commands
dist.run_commands()
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 969, in run_commands
self.run_command(cmd)
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/dist.py", line 1233, in run_command
super().run_command(command)
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
cmd_obj.run()
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/normal/lib/python3.10/site-packages/wheel/bdist_wheel.py", line 349, in run
self.run_command("build")
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/_distutils/cmd.py", line 318, in run_command
self.distribution.run_command(command)
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/dist.py", line 1233, in run_command
super().run_command(command)
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
cmd_obj.run()
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/_distutils/command/build.py", line 131, in run
self.run_command(cmd_name)
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/_distutils/cmd.py", line 318, in run_command
self.distribution.run_command(command)
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/dist.py", line 1233, in run_command
super().run_command(command)
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
cmd_obj.run()
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/command/build_ext.py", line 88, in run
_build_ext.run(self)
File "/private/var/folders/y_/ncmm55ls1zzg41kl5w5z64t80000gp/T/pip-build-env-1qqembnf/overlay/lib/python3.10/site-packages/setuptools/_distutils/command/build_ext.py", line 345, in run
self.build_extensions()
File "<string>", line 81, in build_extensions
File "/opt/homebrew/Cellar/[email protected]/3.10.12/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 421, in check_output
return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
File "/opt/homebrew/Cellar/[email protected]/3.10.12/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 526, in run
raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['cmake', '--version']' returned non-zero exit status 1.
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for qdldl
Failed to build qdldl
ERROR: Could not build wheels for qdldl, 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.
However, with exactly the same env and steps, I can install osqp==0.6.1
successfully.
from osqp-python.
Related Issues (20)
- Error in building wheel for osqp because "No module named cmake' " HOT 1
- No wheels for Python 3.11 HOT 1
- Numpy 1.24 breaks builtin type aliases HOT 1
- symbol not found in flat namespace '_csc_matrix'
- Python solve is faster than C code-generated one HOT 4
- FLOAT codegen argument doesn't work as expected
- Install fails because of metadata version on Mac OS HOT 14
- Apparent non-determinism when using OSQP via CVXPY HOT 5
- Turn solving verbosity off HOT 1
- no ‘cuda pcg’ support
- OSQP.update and scaling error
- unit test failures with scipy 1.12 HOT 2
- Enhancements for skbuild migration HOT 1
- OSQP requirement of scipy < 1.12.0 slows applications down on Apple Silicon HOT 3
- Wrap generated C code with tiny python functionalities HOT 1
- Integrate new codegen with cvxpygen HOT 1
- Add CONTRIBUTING.md
- Support codegen in editable install HOT 1
- Add macOS arm64 wheel HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from osqp-python.