From 01e5aad630d8ded846ea86a0a0649a49117f28cb Mon Sep 17 00:00:00 2001 From: Takashi Kajinami Date: Fri, 1 Nov 2024 01:34:10 +0900 Subject: [PATCH] Replace netutils function to keep non-strict IPv4 check oslo.utils is updating the default strict mode for is_valid_ipv4[1] because the current default was deprecated in 4.8.0[2]. Replace the usage of is_valid_ipv4 to keep using the non-strict mode. [1] https://review.opendev.org/c/openstack/oslo.utils/+/903924 [2] https://review.opendev.org/c/openstack/oslo.utils/+/773863 Change-Id: I1e549209336721b00db3200439964bd697b39238 --- neutron/common/ovn/utils.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/neutron/common/ovn/utils.py b/neutron/common/ovn/utils.py index 4f6fc929336..1b2d9c06ffb 100644 --- a/neutron/common/ovn/utils.py +++ b/neutron/common/ovn/utils.py @@ -565,9 +565,7 @@ def remove_macs_from_lsp_addresses(addresses): """ ip_list = [] for addr in addresses: - ip_list.extend([x for x in addr.split() if - (netutils.is_valid_ipv4(x) or - netutils.is_valid_ipv6(x))]) + ip_list.extend([x for x in addr.split() if netutils.is_valid_ip(x)]) return ip_list