Clean up channel error messages
They had the full schema in them, which was super hard to use.
Change-Id: I6b10859faa1e07e2b644e3c929b2c0e068058c21
diff --git a/aos/events/event_loop.cc b/aos/events/event_loop.cc
index 5b6f5c6..b50162b 100644
--- a/aos/events/event_loop.cc
+++ b/aos/events/event_loop.cc
@@ -142,14 +142,15 @@
ChannelIndex(channel);
CHECK(taken_senders_.find(channel) == taken_senders_.end())
- << ": " << FlatbufferToJson(channel) << " is already being used.";
+ << ": " << configuration::CleanedChannelToString(channel)
+ << " is already being used.";
auto result = taken_watchers_.insert(channel);
- CHECK(result.second) << ": " << FlatbufferToJson(channel)
+ CHECK(result.second) << ": " << configuration::CleanedChannelToString(channel)
<< " is already being used.";
if (!configuration::ChannelIsReadableOnNode(channel, node())) {
- LOG(FATAL) << ": " << FlatbufferToJson(channel)
+ LOG(FATAL) << ": " << configuration::CleanedChannelToString(channel)
<< " is not able to be watched on this node. Check your "
"configuration.";
}
@@ -160,7 +161,8 @@
ChannelIndex(channel);
CHECK(taken_watchers_.find(channel) == taken_watchers_.end())
- << ": Channel " << FlatbufferToJson(channel) << " is already being used.";
+ << ": Channel " << configuration::CleanedChannelToString(channel)
+ << " is already being used.";
// We don't care if this is a duplicate.
taken_senders_.insert(channel);