From 4688c21c54dfb89ef9902b607521a8cc0e99c94a Mon Sep 17 00:00:00 2001 From: Thijs Triemstra Date: Fri, 17 Nov 2023 04:06:13 +0100 Subject: klippy: Replace deprecated logger.warn with logger.warning (#6385) Replace deprecated logger.warn with logger.warning logger.warn will be removed in Python 3.13 Signed-off-by: Thijs Triemstra --- klippy/configfile.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'klippy/configfile.py') diff --git a/klippy/configfile.py b/klippy/configfile.py index dd32d47f..e5c0fb20 100644 --- a/klippy/configfile.py +++ b/klippy/configfile.py @@ -172,16 +172,16 @@ class PrinterConfig: autosave_data = data[pos + len(AUTOSAVE_HEADER):].strip() # Check for errors and strip line prefixes if "\n#*# " in regular_data: - logging.warn("Can't read autosave from config file" - " - autosave state corrupted") + logging.warning("Can't read autosave from config file" + " - autosave state corrupted") return data, "" out = [""] for line in autosave_data.split('\n'): if ((not line.startswith("#*#") or (len(line) >= 4 and not line.startswith("#*# "))) and autosave_data): - logging.warn("Can't read autosave from config file" - " - modifications after header") + logging.warning("Can't read autosave from config file" + " - modifications after header") return data, "" out.append(line[4:]) out.append("") -- cgit v1.2.3-70-g09d2