mobile/cleanup: reduce the noise in our logs

There are two sets of messages that tend to dominate the logs
- the RSSI updates from the Qt BLE stack
- the warnings about deprecated signal use in Kirigami

Neither of them provide any value to us when trying to find bugs; and
often they end up hiding the things that we really care about. So let's
just not log them - which is easy as we have our own message handler.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2021-01-13 14:25:25 -08:00
parent 702d09df9f
commit 4c5997bcbe

View file

@ -39,6 +39,10 @@ void MessageHandlerModel::addLog(QtMsgType type, const QString& message)
if (lastMessage == newMessage)
return;
}
// filter extremely noisy and unhelpful messages
if (message.contains("Updating RSSI for") || (message.contains(QRegExp(".*kirigami.*onFoo properties in Connections"))))
return;
beginInsertRows(QModelIndex(), rowCount(), rowCount());
m_data.append({message, type});
endInsertRows();