From b3ff0214033da644bad3d59d45587f18a5991949 Mon Sep 17 00:00:00 2001 From: Alexander Blume Date: Tue, 23 Jul 2024 13:37:52 +0200 Subject: [PATCH] create warning function --- scripts/func_defs.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/scripts/func_defs.py b/scripts/func_defs.py index 7ea7895..4f1f271 100755 --- a/scripts/func_defs.py +++ b/scripts/func_defs.py @@ -86,6 +86,12 @@ def bail(msg): print(msg, file=sys.stderr) exit(1) + +# print a warning +def warn(msg): + """Print the warning message to stderr.""" + print(f"WARNING: {msg}", file=sys.stderr) + def TrueOrFalse(value): value = repr(value) if value: