From 3436cdaccb2ba83582bec7a7acb8b1b6fbe60ffd Mon Sep 17 00:00:00 2001 From: Stijn de Gooijer Date: Sat, 14 Dec 2024 10:36:15 +0100 Subject: [PATCH] Fix deprecation warning for Python 3.13 --- xlsx2csv.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xlsx2csv.py b/xlsx2csv.py index e6af73d..30f56af 100755 --- a/xlsx2csv.py +++ b/xlsx2csv.py @@ -878,7 +878,7 @@ def handleCharData(self, data): else: # ignore ";@", don't know what does it mean right now # ignore "[$-409], [$-f409], [$-16001]" and similar format codes - dateformat = re.sub(r"\[\$\-[A-z0-9]*\]", "", format_str, 1) \ + dateformat = re.sub(r"\[\$\-[A-z0-9]*\]", "", format_str, count=1) \ .replace(";@", "").replace("yyyy", "%Y").replace("yy", "%y") \ .replace("hh:mm", "%H:%M").replace("h", "%I").replace("%H%H", "%H") \ .replace("ss", "%S").replace("dddd", "d").replace("dd", "d").replace("d", "%d") \