Browse Source

temporarily mute spam lines

Helge Jung 8 years ago
parent
commit
d306d068f0
1 changed files with 6 additions and 0 deletions
  1. 6 0
      modules/ffpb.py

+ 6 - 0
modules/ffpb.py

@@ -55,6 +55,12 @@ class MsgHandler(SocketServer.BaseRequestHandler):
             print("ERROR: No bot in handle() :-(")
             return
 
+        # temporarily mute spam lines
+        if sender.startswith('gw') and \
+           ('Net::ReadTimeout' in msg or 'SSL_connect (Errno::ECONNRESET)' in msg):
+            print('IGNORING spam message from "' + sender + '": "' + msg + '"')
+            return
+
         target = bot.config.core.owner
         if bot.config.has_section('ffpb'):
             is_public = msg.lstrip().startswith("PUBLIC:")