0
$\begingroup$

Rosanswers logo

I am having some issues with the PYTHONPATH that is set by my ROS environment.

my .bashrc contains the following lines:

source /opt/ros/jade/setup.bash
source /home/x/workspace/devel/setup.bash

If I print my PYTHONPATH in a new bash it looks like this:

PYTHONPATH=/home/x/workspace/devel/lib/python2.7/dist-packages

The PYTHONPATH contains only workspace-specific packages.

This results in failure, when trying to import the catkin package from a python interpreter (as it is for example required when importing a rosnode project in qtcreator)

I investigated this problem a little bit, and it seems as if the first sourcing command sets the

PYTHONPATH=/opt/ros/jade/lib/python2.7/dist-packages

(which is where the catkin package is found) The second sourcing command however resets the path, and only appends the workspace specific part again.

Is this the intended behavior?


Originally posted by martin1412 on ROS Answers with karma: 46 on 2016-01-04

Post score: 0

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

I don't really know what the problem was, I removed the whole workspace and set it up again. It seems to work now


Originally posted by martin1412 with karma: 46 on 2016-01-21

This answer was ACCEPTED on the original site

Post score: 0

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.