From e17a40aaff7ece37fc9869e79c3b9ccae5331fbd Mon Sep 17 00:00:00 2001 From: Athanasius Date: Tue, 15 Mar 2022 13:56:48 +0000 Subject: [PATCH] monitor: Change Journal file regex, because Frontier are being a PITA They've changed it to an ISO8601 style full date/time now. But the Odyssey client still uses the old format. --- monitor.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/monitor.py b/monitor.py index b271b0c31..dc3a12e52 100644 --- a/monitor.py +++ b/monitor.py @@ -80,7 +80,8 @@ class EDLogs(FileSystemEventHandler): # type: ignore # See below _POLL = 1 # Polling is cheap, so do it often _RE_CANONICALISE = re.compile(r'\$(.+)_name;') _RE_CATEGORY = re.compile(r'\$MICRORESOURCE_CATEGORY_(.+);') - _RE_LOGFILE = re.compile(r'^Journal(Alpha|Beta)?\.[0-9]{12}\.[0-9]{2}\.log$') + _RE_LOGFILE = re.compile(r'^Journal(Alpha|Beta)?\.[0-9]{2,4}(-)?[0-9]{2}(-)?[0-9]{2}(T)?[0-9]{2}[0-9]{2}[0-9]{2}' + r'\.[0-9]{2}\.log$') _RE_SHIP_ONFOOT = re.compile(r'^(FlightSuit|UtilitySuit_Class.|TacticalSuit_Class.|ExplorationSuit_Class.)$') def __init__(self) -> None: