From ecfc323ea8e2b8008002c291a9c5d0ca2459603f Mon Sep 17 00:00:00 2001 From: Cameron Patrick Date: Sun, 1 Aug 2004 08:09:23 +0000 Subject: [PATCH] do more logging --- sql-edition/servers/VendServer.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/sql-edition/servers/VendServer.py b/sql-edition/servers/VendServer.py index 6e870ff..4d9aae2 100755 --- a/sql-edition/servers/VendServer.py +++ b/sql-edition/servers/VendServer.py @@ -505,16 +505,17 @@ def do_vend_server(options, config_opts): except (LATClientException, socket.error), e: (exc_type, exc_value, exc_traceback) = sys.exc_info() del exc_traceback - print - print "Connection error: "+str(exc_type)+" "+str(e) - print "Trying again in 5 seconds." + logging.error("Connection error: "+str(exc_type)+" "+str(e)) + logging.info("Trying again in 5 seconds.") sleep(5) continue + try: run_forever(rfh, wfh, options, config_opts) except VendingException: - print - print "Connection died, trying again..." + logging.error("Connection died, trying again...") + logging.info("Trying again in 5 seconds.") + sleep(5) if __name__ == '__main__': options, config_opts = set_stuff_up() -- 2.20.1