how to use python compiled file instead of source code
Hi, i want to launch python node but is there any way i can use .pyc file instead of source .py file?
ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
I compiled my project with compileall
File mentioned in node launch should have execution permission (chmod +x)
Renamed module files in ____pycache____ from ModuleName.cpython-37.pyc to ModuleName.pyc (otherwise it throws Import error)
Changed type to .pyc file in launch file:
<node name="rest_api" pkg="hspr" type="rest.cpython-37.pyc" output="screen">
Then it works OK, even after original python files deleted
Asked: 2020-06-25 02:49:48 -0500
Seen: 482 times
Last updated: Jun 16 '21