From 9da6f5328c714f6bdcbc89cb038e10116ab0bed6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maxime=20=E2=80=9Cpep=E2=80=9D=20Buquet?= Date: Tue, 31 Mar 2020 01:03:57 +0200 Subject: [PATCH] Skip whitespace ping logging MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Maxime “pep” Buquet --- poezio/core/handlers.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/poezio/core/handlers.py b/poezio/core/handlers.py index c8d08441..620d854c 100644 --- a/poezio/core/handlers.py +++ b/poezio/core/handlers.py @@ -1510,6 +1510,10 @@ class HandlerCore: poezio_colored, nickname=char) except: + # Most of the time what gets logged is whitespace pings. Skip. + # And also skip tab updates. + if stanza.strip() != '': + return None log.debug('', exc_info=True) if isinstance(self.core.tabs.current_tab, tabs.XMLTab):