moveit: moveit_commander fails in Kinetic due to pyassimp regression
In Xenial with pyassimp 3.2, importing moveit_commander fails with:
>>> import moveit_commander
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/vol/sandbox/ros/install/lib/python2.7/dist-packages/moveit_commander/__init__.py", line 3, in <module>
from planning_scene_interface import *
File "/vol/sandbox/ros/install/lib/python2.7/dist-packages/moveit_commander/planning_scene_interface.py", line 48, in <module>
import pyassimp
File "/usr/lib/python2.7/dist-packages/pyassimp/__init__.py", line 1, in <module>
from .core import *
File "/usr/lib/python2.7/dist-packages/pyassimp/core.py", line 23, in <module>
from . import structs
ImportError: cannot import name structs
@davetcoleman Did you ever tried to run moveit from python in kinect?
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 40 (21 by maintainers)
Commits related to this issue
- fixed numpy.ndarray indices bug (from #86) (#450) * Implemented fix from @lifangda01 * pyassimp bugfix backward compatibility and exception * pyassimp bugfix: More realistic error raise criteri... — committed to moveit/moveit by Kukanani 7 years ago
- fixed numpy.ndarray indices bug (from #86) (#450) (#563) — committed to moveit/moveit by cschindlbeck 7 years ago
- workaround for https://github.com/ros-planning/moveit/issues/86 — committed to k-okada/moveit by k-okada 7 years ago
- workaround for https://github.com/ros-planning/moveit/issues/86 (#581) * workaround for https://github.com/ros-planning/moveit/issues/86 * leave original comment * add more comment when failed ... — committed to moveit/moveit by k-okada 7 years ago
- Improvements in Planning interface port to ROS 2 (#86) * Adding node to planning_interface * moveit_core planning_interface - library as shared * moveit_core planning_interface - fixing CMakeLi... — committed to JafarAbdi/moveit by ahcorde 5 years ago
Was able to fix it. Pull the latest version from assimp. https://github.com/assimp/assimp.git and build it. make install will copy it to /usr/local/lib. Then go to /port/PyAssimp in the source folder and run python setup.py install. This should create the necessary files in /usr/local/lib/python2.7/dist-packages/pyassimp.
move_group_python_interface.py and using the commander works now flawlessly (tested with 16.04 and kinetic)
I still have this issue, with ros-kinetic-moveit installed and fully updated Ubuntu 16.04 system. It is fixed by doing the following:
pip install --user pyassimp
It requires pyassimp 3.3, installed by default is 3.2.
Following the moveit_commander and fell into this. [Xenial, Kinetic]. Workaround:
python-assimp (<=3.2)
bysudo dpkg --remove --force-depends python-pyassimp
(as apt will remove dependencies also)pyassimp
(3.3) usingsudo -H
flag (to replace the /usr one)sudo pip uninstall pyassimp and then, sudo pip install pyassimp , which will install pyassimp 3.3, solved the problems…may help.
Nope, it only worked for you because the current library version of
pyassimp
on pip when you installed it HAPPENED to be 3.3. Today the current one is 4.1.4, and I get the same error using your same commands. This is not a solution, it’s mere luck.The way to do this is:
If you also have problems with multiple python versions installed, this is an even more robust solution:
Had this problem before: Process finished with exit code 139 (interrupted by signal 11: SIGSEGV) And it seems it was segmentation fault like @Aparun8 said that was caused by pyassimp error. Found a solution here. Only version 4.1.3 or 3.3 works.
By the way, this was revealed by the new integration_tests 😉
Yeah this issue has been a real pain. I have raised an issue to the developers here
I can confirm this fixes the problem and moveit_commander works well
Edit: although adding previously working meshes to the scene now raises an error: