diff options
Diffstat (limited to 'sleekxmpp/xmlstream/handler')
-rw-r--r-- | sleekxmpp/xmlstream/handler/callback.py | 2 | ||||
-rw-r--r-- | sleekxmpp/xmlstream/handler/waiter.py | 3 |
2 files changed, 5 insertions, 0 deletions
diff --git a/sleekxmpp/xmlstream/handler/callback.py b/sleekxmpp/xmlstream/handler/callback.py index c618b718..dd507262 100644 --- a/sleekxmpp/xmlstream/handler/callback.py +++ b/sleekxmpp/xmlstream/handler/callback.py @@ -1,4 +1,5 @@ from . import base +import logging class Callback(base.BaseHandler): @@ -15,6 +16,7 @@ class Callback(base.BaseHandler): self.run(payload, True) def run(self, payload, instream=False): + logging.debug("Running %s in %s" % (self.name, self._pointer)) if not self._instream or instream: base.BaseHandler.run(self, payload) #if self._thread: diff --git a/sleekxmpp/xmlstream/handler/waiter.py b/sleekxmpp/xmlstream/handler/waiter.py index e62f330f..2c91052d 100644 --- a/sleekxmpp/xmlstream/handler/waiter.py +++ b/sleekxmpp/xmlstream/handler/waiter.py @@ -9,15 +9,18 @@ class Waiter(base.BaseHandler): self._payload = queue.Queue() def prerun(self, payload): + logging.debug("Putting into Waiter %s" % self.name) self._payload.put(payload) def run(self, payload): pass def wait(self, timeout=60): + logging.debug("Waiting on %s." % self.name) try: return self._payload.get(True, timeout) except queue.Empty: + logging.warning("Timed out waiting for %s" % self.name) return False def checkDelete(self): |