From 9915ebf3ed8ec4da09f1b41a32c955735b0391cb Mon Sep 17 00:00:00 2001 From: Tim Abbott Date: Wed, 10 Oct 2012 16:33:21 -0400 Subject: [PATCH] zephyr_mirror: Print out the message before logging it. This should make debugging easier. (imported from commit 101bab269b98ee5c2f56780d97e6b94c0887a306) --- zephyr_mirror.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/zephyr_mirror.py b/zephyr_mirror.py index 6f036dd..715dcf1 100644 --- a/zephyr_mirror.py +++ b/zephyr_mirror.py @@ -161,11 +161,11 @@ def process_loop(log): 'zsig' : zsig, # logged here but not used by app 'content' : body } + print "%s: received a message on %s/%s from %s..." % \ + (datetime.datetime.now(), notice.cls, notice.instance, notice.sender) log.write(simplejson.dumps(zeph) + '\n') log.flush() - print "%s: received a message on %s/%s from %s..." % \ - (datetime.datetime.now(), notice.cls, notice.instance, notice.sender) res = send_humbug(zeph) if res.get("result") != "success": print >>sys.stderr, 'Error relaying zephyr'