How to fix this python's roslaunch API error?
I follow this procedure to execute roslaunch file with argument via python like this:
# launch recording program
uuid = roslaunch.rlutil.get_or_generate_uuid(None, False)
roslaunch.configure_logging(uuid)
cli_args = [
'hw_interface',
'main.launch',
'save_path:=/mnt/usb-SanDisk_Ultra_Fit_4C530001151128104110-0:0-part1'
]
roslaunch_file = roslaunch.rlutil.resolve_launch_arguments(cli_args)
roslaunch_args = cli_args[2:]
launch_file = [(roslaunch_file, roslaunch_args)]
parent = roslaunch.parent.ROSLaunchParent(uuid, launch_file)
parent.start()
But it returns this error:
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/config.py", line 450, in load_config_default
logger.info('loading config file %s'%f)
TypeError: not all arguments converted during string formatting
similar question has been asked here but still no answer.
add a comment