How to run ROS with other programs simultaneously, which use python3.5?

asked 2018-03-06 06:09:49 -0500

waschbaer00 gravatar image

Hi there,

how to solve the problem when I run ROS and other programs use python3.5 as the same time? When ROS is running, the path is ros/kinetic/../python2.7, which indicates that ROS is using python2.7.

Actually my question should consist of two parts:

  1. how to solve python2.7 and python3.5 conflict? Docker? Virtual Env?
  2. If the program need usr/local/python2.7, will there still a conflict to ROS? Because ROS uses ros/kinetic/../python2.7.

BTW, I don't want a ROS python3 version, because I feel not confident on py3 version.

I have Ubuntu 16.04, ROS kinetic.

Thank you.

Best, bear

edit retag flag offensive close merge delete

Comments

Next time, please don't delete your question. You can always edit it (this means the title, tags, and content). Now everything that we were working in yesterday is gone.

jayess gravatar image jayess  ( 2018-03-06 11:02:22 -0500 )edit

Like I was asking about your previous (same) question, what do you mean by the same time? Are you trying to run two different programs at the same time or from the same program? Are you getting any errors? Anything else that could help us? This question is a little vague to me.

jayess gravatar image jayess  ( 2018-03-06 11:04:55 -0500 )edit

We didn't work on anything at all yesterday, you just complaint I didn't describe problem clearly. Since you have misunderstandings, I would like to re-write my question.

waschbaer00 gravatar image waschbaer00  ( 2018-03-06 12:47:05 -0500 )edit

Working on coming to an understanding of your problem is work. No need to create a new question to re-write your question, you can just edit it.

jayess gravatar image jayess  ( 2018-03-06 12:48:24 -0500 )edit

Go back to my question: I said, when I run ROS node, the other program, which is not the ros node, can not be ran, the reason for that is because ROS indicate to use its own python under the path ros/kinetic/.../python2.7, and the program use 3.5, and it is global. Basically I just repeating.

waschbaer00 gravatar image waschbaer00  ( 2018-03-06 12:48:30 -0500 )edit

How are you trying to run your Python 3.5 program and ROS node?

jayess gravatar image jayess  ( 2018-03-06 12:51:00 -0500 )edit

For me it is hard to understand what is running two same program at the same time, why I want to run two same programs?

waschbaer00 gravatar image waschbaer00  ( 2018-03-06 12:51:09 -0500 )edit

first start roscore, second open a new terminal and type python3 main.py

waschbaer00 gravatar image waschbaer00  ( 2018-03-06 12:53:41 -0500 )edit