diff --git a/pdf_oralia/pages/charge.py b/pdf_oralia/pages/charge.py index 8a0a796..b7b9f9c 100644 --- a/pdf_oralia/pages/charge.py +++ b/pdf_oralia/pages/charge.py @@ -30,7 +30,7 @@ def is_it(page_text): def get_lot(txt): """Return lot number from "RECAPITULATIF DES OPERATIONS" """ - regex = r"[BSM](\d+)\s-" + regex = r"[BSM](\d+)(?=\s*-)" result = re.findall(regex, txt) if result: return "{:02d}".format(int(result[0]))