Enable Ruff FLY002 rule (#115112)
Co-authored-by: J. Nick Koston <nick@koston.org> Co-authored-by: Jan Bouwhuis <jbouwh@users.noreply.github.com>
This commit is contained in:
parent
35d3f2b29b
commit
9bf87329da
41 changed files with 474 additions and 659 deletions
|
@ -62,7 +62,7 @@ def _normalize_ips_and_network(hosts_str: str) -> list[str] | None:
|
|||
start, end = host.split("-", 1)
|
||||
if "." not in end:
|
||||
ip_1, ip_2, ip_3, _ = start.split(".", 3)
|
||||
end = ".".join([ip_1, ip_2, ip_3, end])
|
||||
end = f"{ip_1}.{ip_2}.{ip_3}.{end}"
|
||||
summarize_address_range(ip_address(start), ip_address(end))
|
||||
except ValueError:
|
||||
pass
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue