ROS2 remove warning from Rviz2 when gazebo is loading
Hello, I am using ros2 foxy with ubuntu 20.04 and rviz2
I have built a system for my robot that uses ekf nodes to publish the map -> odom and odom -> base_link tf However these nodes need to have gazebo running as it will publish the /odom and /imu topics needed.
When i start my application, rviz load after 1 sec but gazebo takes more time so rviz flood the log with :
[rviz2-6] Warning: Invalid frame ID "odom" passed to canTransform argument target_frame - frame does not exist
[rviz2-6] at line 133 in /tmp/binarydeb/ros-foxy-tf2-0.13.13/src/buffer_core.cpp
Is there a way to start rviz only after the gazebo node is started and working ?
I know i could use some delay to start rviz but either i have to wait if gazebo launch quickly or sometimes the delay is not enough .. this greatly depend on the computer I use. I figured there would be a way to just wait for gazebo to start or wait for a topic to be published before running rviz ?
Or even throttling that log would be nice to just 1 time a second... I completely agree.