-
Notifications
You must be signed in to change notification settings - Fork 408
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Python Version Error #428
Comments
Good question. Pybind11 might be finding its own python version instead of using the already found version. Try running with the most recent commit, 89e26e0, on master. As we both swtich the way python is found and we have updated to a newer pybind11 version. |
@MatthijsBurgh I have already used the latest version: "commit 89e26e0 (HEAD -> master, origin/master, origin/HEAD) When I did the cmake, I have already given the conda python 3.7 directory to DPYTHON_EXECUTABLE, but the cmake used the system python 3.8 to compile. Stuck here for one day, please help. Thanks. |
@MatthijsBurgh And, I did the install again, use the latest commit. another error came out "ImportError: liborocos-kdl.so.1.5: cannot open shared object file: No such file or directory" I am using miniconda3+ python3.7 to use KDL. Thanks. |
The log you provided in your first message is definitely from before #425. As that was finding the Python Interpreter. Now the logs should look like this, where it find the python executable. Using CATKIN_DEVEL_PREFIX: /home/matthijs/ros/noetic/system/devel/.private/python_orocos_kdl
-- Using CMAKE_PREFIX_PATH: /home/matthijs/ros/noetic/system/devel;/opt/ros/noetic
-- This workspace overlays: /home/matthijs/ros/noetic/system/devel;/opt/ros/noetic
-- Using PYTHON_EXECUTABLE: /usr/bin/python3
-- Using Debian Python package layout
-- Using empy: /usr/lib/python3/dist-packages/em.py
-- Using CATKIN_ENABLE_TESTING: OFF
-- catkin 0.8.10
-- BUILD_SHARED_LIBS is on
-- pybind11 not found, building from source
-- pybind11 v2.10.2
-- Configuring done
-- Generating done
-- Build files have been written to: /home/matthijs/ros/noetic/system/build/python_orocos_kdl |
This sounds very much like a configuration issue. I don't work with conda environments. And especially not in combination with a catkin ws. Just make sure all your environments/ws are sourced correctly and in the correct order. (Don't ask me what the correct order is.) So the resulting environment variables and paths are correct. |
Stale |
Hi, I installed the PyKDL, but when I import PyKDL, the error came out
ImportError: Python version mismatch: module was compiled for Python 3.8, but the interpreter version is incompatible: 3.7.15 (default, Nov 24 2022, 21:12:53) [GCC 11.2.0].
.I am using UBUNTU 20.04. When i installed, I used:
cmake ../ -DPYTHON_EXECUTABLE:FILEPATH=/home/walter/miniconda3/envs/Robot_ur5e_ws/bin/python
And it showed:
I am not sure what is wrong, please help.
Thanks!
The text was updated successfully, but these errors were encountered: