`ros2 param dump` silently overwrites existing file
See original GitHub issueBug report
Required Info:
- Operating System:
- Ubuntu 20.04
- Installation type:
- Debian packages
- Version or commit hash:
- ros-rolling-ros2param 0.13.0-1
- DDS implementation:
- CycloneDDS
- Client library (if applicable):
- rclpy
Steps to reproduce issue
In terminal 1:
ros2 run turtlesim turtlesim_node
In terminal 2:
echo "foo" > turtlesim.yaml # turtlesim.yaml now contains "foo"
ros2 param dump /turtlesim # this overwrites the existing turtlesim.yaml, which may be surprising
Expected behavior
When ros2 param dump
is choosing a filename, it should either error out if a file with the name it chose already exists, or it should keep choosing names until it finds one that has no conflict.
Actual behavior
ros2 param dump
silently ovewrites the existing file.
Issue Analytics
- State:
- Created 2 years ago
- Comments:6 (6 by maintainers)
Top Results From Across the Web
ROS2 Dashing overwrite default param via yaml - ROS Answers
When running the node, it should be possible to pass a .yaml file with some updated values for one ore more parameters.
Read more >Commands - PX4 Developer Guide
Dump file utility. Prints file size and contents in binary mode (don't replace LF with CR LF) to stdout. Usage. dumpfile [arguments.
Read more >Tutorial 4: The launch utility — 240AR060 - Introduction to ROS
Objective: This tutorial session is devoted to learn the ROS mechanism for starting the master and many nodes all at once, using a...
Read more >Changelog — MARV Robotics 21.12.0 documentation - GitLab
Deprecated . 21.12.0 will remove support for ROS1 message type names, use new ROS2 names instead ... Check not to overwrite existing...
Read more >s700_800 11.00 PM/VM/UFS/async/scsi/io/DMAPI/JFS/perf patch ...
Under rare conditions, numerous simultaneous access to files on VxFS file systems ... SHMEM_MAGIC processes core dump while trying to access shared memory....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Sometimes it is practical for it to just overwrite it. Perhaps making opt-in would be best.
That’s a pretty good idea, I like it. This is also more Unix-y; you could always do
ros2 param dump /turtlesim > turtlesim.yaml
.The downside is that this breaks compatibility with earlier releases. That is, in Foxy, if you do
ros2 param dump /turtlesim
, by default it writes to a file. If you then pass--print
, it prints to stdout. If we were to make this change, then in Galacticros2 param dump /turtlesim
would print to stdout, and passing--write <fname>
(or whatever) would write it to a file.I don’t know, how do people feel about a command-line break like that?