Suppress spam from calling canTransform#529
Conversation
Signed-off-by: Gonzalo de Pedro <gonzalo@depedro.com.ar>
|
Do you mind also updating these other calls (from my other comment #502 (comment)): geometry2/tf2_ros/src/buffer.cpp Line 94 in ef2dd14 geometry2/tf2_ros/src/buffer.cpp Line 117 in ef2dd14 |
The user has few options to workaround potential console spam from canTransform. If we want, it would be better to update the API to optional return the error string. Signed-off-by: Jacob Perron <jacob@openrobotics.org>
clalancette
left a comment
There was a problem hiding this comment.
Not to derail this, but I will point out that suppressing these error messages unconditionally basically constitutes a large behavior change in tf2_ros from previous versions. It also means that we won't get notified of real errors in the tf2 tree (like loops).
I'm not quite sure what we want to do here. Maybe it would be a better idea to rate-limit this instead of suppressing it completely, as we are going to be losing a lot of debugging information this way.
|
The code is a bit tangled, but I think these are the two behavior changes caused by this PR:
Correct me if I'm wrong, but I don't think (1) is disagreeable. Regarding (2), the code is a bit hard to follow, but in both the previous and current behavior an exception is thrown from geometry2/tf2/src/buffer_core.cpp Lines 124 to 145 in 51a7f24 called from lookupTransform's implementation: geometry2/tf2/src/buffer_core.cpp Lines 654 to 655 in 51a7f24 The only difference this PR introduces is that we don't get the (more or less) same message repeated to the console before the exception ultimately occurs. AFAICT, we're only calling I agree that the underlying issue of |
|
If I'm not mistaken, this change doesn't hide errors in the TF tree since |
|
@clalancette friendly ping 🙂 |
Agreed, this is desirable. The part of the patch that changes
And now looking at it in more detail, I agree with you. So with all of that said, I'm going to approve this. Thanks for the detailed explanation on what is going on here. |
|
@jacobperron |
* suppress spam in canTransform * Uncrustify Signed-off-by: Gonzalo de Pedro <gonzalo@depedro.com.ar> * Suppress console spam in other calls to canTransform The user has few options to workaround potential console spam from canTransform. If we want, it would be better to update the API to optional return the error string. Signed-off-by: Jacob Perron <jacob@openrobotics.org> Signed-off-by: Gonzalo de Pedro <gonzalo@depedro.com.ar> Signed-off-by: Jacob Perron <jacob@openrobotics.org> Co-authored-by: Grigoriy Lipenko <gnlipenko@sberautotech.ru> Co-authored-by: Jacob Perron <jacob@openrobotics.org>
|
Was this feature ever ported to humble? I am getting lots of messages in my tests, they make debugging a lot more difficult |
|
@Mergifyio backport humble |
✅ Backports have been createdDetails
|
* suppress spam in canTransform * Uncrustify Signed-off-by: Gonzalo de Pedro <gonzalo@depedro.com.ar> * Suppress console spam in other calls to canTransform The user has few options to workaround potential console spam from canTransform. If we want, it would be better to update the API to optional return the error string. Signed-off-by: Jacob Perron <jacob@openrobotics.org> Signed-off-by: Gonzalo de Pedro <gonzalo@depedro.com.ar> Signed-off-by: Jacob Perron <jacob@openrobotics.org> Co-authored-by: Grigoriy Lipenko <gnlipenko@sberautotech.ru> Co-authored-by: Jacob Perron <jacob@openrobotics.org> (cherry picked from commit 8c2aa5a)
* suppress spam in canTransform * Uncrustify Signed-off-by: Gonzalo de Pedro <gonzalo@depedro.com.ar> * Suppress console spam in other calls to canTransform The user has few options to workaround potential console spam from canTransform. If we want, it would be better to update the API to optional return the error string. Signed-off-by: Jacob Perron <jacob@openrobotics.org> Signed-off-by: Gonzalo de Pedro <gonzalo@depedro.com.ar> Signed-off-by: Jacob Perron <jacob@openrobotics.org> Co-authored-by: Grigoriy Lipenko <gnlipenko@sberautotech.ru> Co-authored-by: Jacob Perron <jacob@openrobotics.org> (cherry picked from commit 8c2aa5a) Co-authored-by: Gonzo <42421541+gonzodepedro@users.noreply.github.com>
Based on #502
Closes #501