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

invalid preprocessing directive #!

asked 2020-08-31 18:59:20 -0500

aselya gravatar image

I'm trying to build a dynamic configuration for a cpp application and I'm adapting the tutorial. I'm getting the following error in my cfg file. Any insight you have will be appreciated.

error: invalid preprocessing directive #! 2 | #!/usr/bin/env python

I've already tried chmod a+x on the file python version is 3.8.2

edit retag flag offensive close merge delete

Comments

Can you please update your question and add a copy of your cfg file? It looks to me like the most likely cause is an improperly formatted first line. Your cfg file should have only the following on the first line: #!/usr/bin/env python. No extra characters or spaces.

jarvisschultz gravatar image jarvisschultz  ( 2020-09-01 09:09:31 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2020-09-04 09:33:43 -0500

aselya gravatar image

I fixed it by removing an accidental space in the file

edit flag offensive delete link more

Question Tools

Stats

Asked: 2020-08-31 18:59:20 -0500

Seen: 1,373 times

Last updated: Aug 31 '20