ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
Thank for @dgyx's solution. I also have this problem when I run the roscore command after I have installed Matlab MCR on my Ubuntu 1404 32bit system.
Traceback (most recent call last): File "/opt/ros/indigo/bin/roscore", line 69, in <module> import roslaunch File "/opt/ros/indigo/lib/python2.7/dist-packages/roslaunch/__init__.py", line 48, in <module> import rospkg File "/usr/lib/python2.7/dist-packages/rospkg/__init__.py", line 43, in <module> from .rospack import RosPack, RosStack, \ File "/usr/lib/python2.7/dist-packages/rospkg/rospack.py", line 35, in <module> from xml.etree.cElementTree import ElementTree File "/usr/lib/python2.7/xml/etree/cElementTree.py", line 3, in <module> from _elementtree import * ImportError: PyCapsule_Import could not import module "pyexpat"
I add the library path of my system - "/lib/i386-linux-gnu" - in $LD_LIBRARY_PATH in front of Matlab's lib paths. Then the problem is solved. By the way, only adding system library path in front of Matlab's paths works.
2 | No.2 Revision |
Thank for @dgyx's solution. I also have this problem when I run the roscore command after I have installed Matlab MCR on my Ubuntu 1404 32bit system.
Traceback (most recent call last):
File "/opt/ros/indigo/bin/roscore", line 69, in <module>
import roslaunch
File "/opt/ros/indigo/lib/python2.7/dist-packages/roslaunch/__init__.py", line 48, in <module>
import rospkg
File "/usr/lib/python2.7/dist-packages/rospkg/__init__.py", line 43, in <module>
from .rospack import RosPack, RosStack, \
File "/usr/lib/python2.7/dist-packages/rospkg/rospack.py", line 35, in <module>
from xml.etree.cElementTree import ElementTree
File "/usr/lib/python2.7/xml/etree/cElementTree.py", line 3, in <module>
from _elementtree import *
ImportError: PyCapsule_Import could not import module I add the library path of my system - "/lib/i386-linux-gnu" /lib/i386-linux-gnu
- in $LD_LIBRARY_PATH $LD_LIBRARY_PATH
in front of Matlab's lib paths. Then the problem is solved. By the way, only adding system library path in front of Matlab's paths works.