Add more logging
This commit is contained in:
parent
43cae42f57
commit
6ee35ec279
|
@ -9,7 +9,7 @@ from sasl import nick, password
|
|||
from users import USERS
|
||||
|
||||
|
||||
LOG_FORMAT = "%(asctime)s [%(levelname)s] <%(filename)s> %(funcName)s: %(message)s"
|
||||
LOG_FORMAT = "%(asctime)s [%(levelname)s] %(threadName)s <%(filename)s> %(funcName)s: %(message)s"
|
||||
logging.basicConfig(format=LOG_FORMAT, level=logging.DEBUG)
|
||||
|
||||
channels = ["hs", "projets", "annonces"]
|
||||
|
|
2
irc.py
2
irc.py
|
@ -30,6 +30,7 @@ class IRC(object):
|
|||
""" Start the IRC layer. Manage authentication as well """
|
||||
sasl_nick = sasl_nick or nick
|
||||
self.running = True
|
||||
logging.debug("Thread start")
|
||||
self._handler.start()
|
||||
|
||||
self._send(f"USER {nick} * * :{nick}")
|
||||
|
@ -110,7 +111,6 @@ class IRC(object):
|
|||
elif len(m):
|
||||
if store:
|
||||
self._inbox.put(m)
|
||||
logging.debug(f"received {m}")
|
||||
|
||||
def _send(self, raw):
|
||||
""" Wrap and encode raw message to send """
|
||||
|
|
|
@ -27,6 +27,7 @@ class Shoutbox(object):
|
|||
|
||||
def run(self):
|
||||
self.running = True
|
||||
logging.debug("Thread start")
|
||||
self._handler.start()
|
||||
|
||||
def stop(self):
|
||||
|
|
Loading…
Reference in New Issue