ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

import in rosgraph/ failing

asked 2015-07-05 20:29:57 -0600

Mica gravatar image

updated 2015-07-06 18:19:51 -0600


I am getting an error in the rosgraph/ file.

I am trying to run the turtlebot_arm_bringup arm.launch from answer17 and am also using their arbotix package. I am using these packages as they appear to provide support for the pincher arm I am using.

I am using Indigo on Ubuntu 14.04, with Python 2.7.6.

The error I get is:

$ roslaunch turtlebot_arm_bringup arm.launch 

Traceback (most recent call last):
File "/opt/ros/indigo/bin/roslaunch", line 34, in <module>
import roslaunch
File "/opt/ros/indigo/lib/python2.7/dist-packages/roslaunch/", line 50, in <module>
from . import core as roslaunch_core
 File "/opt/ros/indigo/lib/python2.7/dist-packages/roslaunch/", line 47, in <module>
from xmlrpclib import MultiCall, ServerProxy
 File "/usr/lib/python2.7/", line 145, in <module>
import httplib
  File "/usr/lib/python2.7/", line 79, in <module>
import mimetools
  File "/usr/lib/python2.7/", line 6, in <module>
import tempfile
File "/usr/lib/python2.7/", line 32, in <module>
import io as _io
File "/opt/ros/indigo/lib/python2.7/dist-packages/rospy/", line 49, in <module>
from .client import spin, myargv, init_node, \
  File "/opt/ros/indigo/lib/python2.7/dist-packages/rospy/", line 49, in <module>
import rosgraph
  File "/opt/ros/indigo/lib/python2.7/dist-packages/rosgraph/", line 36, in <module>
from . masterapi import Master, MasterFailure, MasterError, MasterException

File "/opt/ros/indigo/lib/python2.7/dist-packages/rosgraph/", line 43, in <module>
from xmlrpclib import ServerProxy  # Python 2.x
ImportError: cannot import name ServerProxy

So it looks like python can find (so don't think it's a PYTHONPATH issue) but I'm not sure why it can't import ServerProxy (it exists in this file). Any ideas on what is going wrong?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2015-07-28 04:19:46 -0600

Mica gravatar image

Turns out a few of the ros commands were missing (when I uninstalled a Turtlebot package using sudo apt-get install it deleted some other packages and was perhaps the cause of this...).

edit flag offensive delete link more

Question Tools


Asked: 2015-07-05 20:29:57 -0600

Seen: 366 times

Last updated: Jul 28 '15