From 928fa916711712005b9fb2c9197718bb2c818948 Mon Sep 17 00:00:00 2001 From: BodgeMaster <> Date: Mon, 14 Feb 2022 14:22:46 +0100 Subject: [PATCH] added a function for debug/info logging --- main.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/main.py b/main.py index b111acf..2383510 100644 --- a/main.py +++ b/main.py @@ -13,6 +13,10 @@ EXIT_ERROR=1 default_configuration = { "window geometry": "640x480" } +def info(message): + # print info to sys.stderr because it isn’t really output, just debug information + print("INFO: "+str(message), file=sys.stderr) + traceback.print_stack() def warn(message, is_exception=False): print("WARNING: "+str(message), file=sys.stderr)