You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
moveit_commander fails in Kinetic due to pyassimp regression #86
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?
Seems like this issue should be left open until fixed for other user's reference, or we should document it somewhere else like the moveit_command tutorial
I just tried running the python move_group_interface tutorial and ran into this bug again. I just checked the launchpad link and even though they claim it has been released, Ubuntu 16.04 still lacks the fixed version. I asked a question on that forum, not sure how else to proceed.
same problem here. Moveit commander is not usable due to ImportError: cannot import name structs. Is there a way to use moveit from python without using the commander? I basically need only a move_to for the endeffector (of Baxter).
move_group_python_interface.py and using the commander works now flawlessly (tested with 16.04 and kinetic)
Reacted by Robby Candra, Chiel Bruin, jlack1987, Tadinu, Toby Buckley, Keerthana Manivannan, Andrew Dahdouh, Eric Heiden, AndyChou007, toru-kuga and 13 more
I looked into modifying the rosdep keys so we can install pyassimp from pip2 and use apt to install libassimp-dev. However, rosdep is not configured to accept a particular version of pip.
I just tested in a pristine docker installing pyassimp via pip install pyassimp and then apt install libassimp-dev and that combo imported just fine. That should be all that's needed for it to work with rosdep right? I didn't have to specify pip2 or pip3
The problem is worked around in f00addf and things work if you build moveit/the moveit_commander package yourself.
However it is still not released in kinetic. We are on our way to release (hopefully) next week (see #686).
I believe it is an old version that's released with Ubuntu. I recommend
first checking which version pip installs and if newer Ubuntu versions have
this issue, it may only be broken in Kinetic but working in Melodic.
We could use a different library to load meshes in kinetic or both if still
broken in Ubuntu bionic.
Segmentation fault(Core dumped) while adding mesh files to moveit. I updated the pyassimp version to 4.1.3 after some advice, but still I'm getting the same error. Importing moveit_commander works. Adding default shapes to moveit works, but adding meshfiles doesn't works. And the error comes when I add mesh files. I tried with both absolute and relative paths. Any help would be appreciated.
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.
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.
Activity
rhaschke commentedon Aug 19, 2016
By the way, this was revealed by the new integration_tests ;-)
rhaschke commentedon Aug 19, 2016
The bug is already filed on launchpad and a patch exists.
davetcoleman commentedon Aug 19, 2016
No, I don't use commander or any Python interfaces
davetcoleman commentedon Aug 19, 2016
Nice job with the integration tests!!
v4hn commentedon Aug 22, 2016
@rhaschke can we close this? It's a bug in the ubuntu package that should be fixed in a while (I presume).
davetcoleman commentedon Aug 22, 2016
Seems like this issue should be left open until fixed for other user's reference, or we should document it somewhere else like the moveit_command tutorial
v4hn commentedon Aug 22, 2016
On Mon, Aug 22, 2016 at 11:21:52AM -0700, Dave Coleman wrote:
Ok, let's leave it open then.
davetcoleman commentedon Nov 3, 2016
I just tried running the python move_group_interface tutorial and ran into this bug again. I just checked the launchpad link and even though they claim it has been released, Ubuntu 16.04 still lacks the fixed version. I asked a question on that forum, not sure how else to proceed.
MarkusEich commentedon Nov 25, 2016
same problem here. Moveit commander is not usable due to ImportError: cannot import name structs. Is there a way to use moveit from python without using the commander? I basically need only a move_to for the endeffector (of Baxter).
davetcoleman commentedon Nov 25, 2016
You can try https://github.com/mikeferguson/moveit_python - I'd like to eventually integrate that into our main release
MarkusEich commentedon Nov 30, 2016
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)
130s commentedon Jan 11, 2017
I suppose this can be closed now that Kinetic release #18 is already done. Please report/reopen if the issue persists.
19 remaining items
srsidd commentedon Jul 7, 2017
I looked into modifying the
rosdepkeys so we can installpyassimpfrompip2and useaptto installlibassimp-dev. However,rosdepis not configured to accept a particular version of pip.@jlack1987 has opened an issue here, (rosdep/issues/519), which is technically a blocker for this to get done.
jlack1987 commentedon Jul 8, 2017
I just tested in a pristine docker installing pyassimp via
pip install pyassimpand thenapt install libassimp-devand that combo imported just fine. That should be all that's needed for it to work withrosdepright? I didn't have to specifypip2orpip3fixed numpy.ndarray indices bug (from #86) (#450) (#563)
0ldham commentedon Aug 1, 2017
I still receive the initial structs error, even after following the advice of @MarkusEich and of @iglstone, and after updating moveit and pyassimp.
workaround for moveit#86
k-okada commentedon Aug 9, 2017
as @0ldham reported, we still have this problem, our proposal patch is #581
workaround for #86 (#581)
jacknlliu commentedon Nov 6, 2017
We still have this problem.
v4hn commentedon Nov 17, 2017
The problem is worked around in f00addf and things work if you build moveit/the
moveit_commanderpackage yourself.However it is still not released in kinetic. We are on our way to release (hopefully) next week (see #686).
naveedhd commentedon Dec 4, 2017
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 -Hflag (to replace the /usr one)bmagyar commentedon May 24, 2018
Aparun8 commentedon Mar 24, 2019
Segmentation fault(Core dumped) while adding mesh files to moveit. I updated the pyassimp version to 4.1.3 after some advice, but still I'm getting the same error. Importing moveit_commander works. Adding default shapes to moveit works, but adding meshfiles doesn't works. And the error comes when I add mesh files. I tried with both absolute and relative paths. Any help would be appreciated.
tandukion commentedon Apr 8, 2019
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.
dbersan commentedon Aug 7, 2020
Nope, it only worked for you because the current library version of
pyassimpon 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:
pip install 'pyassimp>=3.3.0,<3.4.0' --force-reinstallIf you also have problems with multiple python versions installed, this is an even more robust solution:
sudo python -m pip install 'pyassimp>=3.3.0,<3.4.0' --force-reinstallImprovements in Planning interface port to ROS 2 (moveit#86)