nicer output

This commit is contained in:
Luke Rogers 2013-10-03 23:20:27 +13:00
parent 6f3a10527e
commit c2271b1195
2 changed files with 2 additions and 2 deletions

View file

@ -31,7 +31,7 @@ def get_logger():
# create a formatter and set the formatter for the handler.
frmt = logging.Formatter('%(asctime)s [%(levelname)s] %(message)s')
fh.setFormatter(frmt)
simple_frmt = logging.Formatter('[%(levelname)s] %(message)s')
simple_frmt = logging.Formatter('%(message)s')
sh.setFormatter(simple_frmt)
# add the Handlers to the logger

View file

@ -104,7 +104,7 @@ class SendThread(threading.Thread):
def run(self):
while not self.shutdown:
line = self.output_queue.get().splitlines()[0][:500]
print u"{}>>> {}".format(self.conn_name, line)
print u"{}> {}".format(self.conn_name, line)
self.output_buffer += line.encode('utf-8', 'replace') + '\r\n'
while self.output_buffer:
sent = self.socket.send(self.output_buffer)