vscode-ros icon indicating copy to clipboard operation
vscode-ros copied to clipboard

Could not source the setup file for ROS distro "melodic"

Open scout208 opened this issue 6 years ago • 5 comments

I configured my distro to melodic through the pop-up msg, and now I get a notification that says Could not source the setup file for ROS distro "melodic". Furthermore my #include "ros/ros.h" and #include "std_msgs/String.h" statements are showing errors.

See the image below:

image

scout208 avatar Nov 29 '18 21:11 scout208

I met the same problems and looking forward to having somebody help.

cnodon avatar Jan 03 '19 08:01 cnodon

mabe you should try ROS VSCode Extension, it can add a .json automaticly.I met similar problem like yours and I dont know how to fix it.my code can compile successfully and run successfully but VScode still show the red err to me.and I looking forward to having somebody help. image

Suyixiu avatar Jan 06 '19 12:01 Suyixiu

emmmmm,我的问题也找到了。把ros.h设置成g++的CPLUS_INCLUDE_PATH就好了。然后就不会再有烦人的红色波浪线了。emmmm这样一个小问题真是让人揪心啊,不过解决了就好哈哈哈哈。

Suyixiu avatar Jan 06 '19 19:01 Suyixiu

Hi @scout208 , were you able to fix that issue? I have the same. I can manually make the connections to the include files of ROS and get rid of wave underlines. I can also use ROS and Catkin commands from command line. But I still have that error message, and can not use the functionality of the extension in VSCode.

mythody avatar Jun 12 '19 15:06 mythody

@KirillSum No, I gave up on my end.

scout208 avatar Jun 12 '19 20:06 scout208