diff --git a/ansible/library/extract_log.py b/ansible/library/extract_log.py index 1f5fcc8f17e..2594ecd2e76 100644 --- a/ansible/library/extract_log.py +++ b/ansible/library/extract_log.py @@ -168,6 +168,9 @@ def convert_date(fct, s): locale.setlocale(locale.LC_ALL, loc) + if dt is None: + dt = 0 + logger.warning(f"Failed to convert date from string, skipping unparseable line: {s}") return dt