From: Christian Heller Date: Thu, 4 Sep 2025 01:34:58 +0000 (+0200) Subject: Avoid zero-length task path steps. X-Git-Url: https://plomlompom.com/repos/new_day?a=commitdiff_plain;h=af7a3b6bdc455e3ceb965101fa7dbe5ccc69ebe1;p=ircplom Avoid zero-length task path steps. --- diff --git a/ircplom/msg_parse_expectations.py b/ircplom/msg_parse_expectations.py index c91ff3e..585f25b 100644 --- a/ircplom/msg_parse_expectations.py +++ b/ircplom/msg_parse_expectations.py @@ -26,7 +26,7 @@ class _Command(NamedTuple): def from_(cls, input_: str) -> Self: 'Split by first "_" into verb, path (split into steps tuple by ".").' verb, path_str = input_.split('_', maxsplit=1) - return cls(verb, tuple(path_str.split('.'))) + return cls(verb, tuple(step for step in path_str.split('.') if step)) class _MsgParseExpectation: