Updated script to use same logic (and error message) as roslaunch with respect to attempting to override the value of an argument whose 'value' attribute is specified.
Updated script to use same logic (and error message) as roslaunch with respect to attempting to override the value of an argument whose 'value' attribute is specified.

This script will print the warning, but not fail (and still produce a graph). It will also not use the value that is attempted to be overriden.

Take the following launch file as an example:

    <launch>
        <arg name="test" value="123" />
    </launch>

Calling the following command:

    ./roslaunch_to_dot.py example.launch example.dot test:=321

Will produce a warning indicating:

    WARNING: cannot override arg 'test', which has already been set

The value of arg will be 123, and not 321.

bponsler/roslaunch_to_dot,bponsler/roslaunch_to_dot