From 83de09839611cd89200ca2678918ee61de05c6a3 Mon Sep 17 00:00:00 2001 From: Open vSwitch CI Date: May 23 2024 14:04:55 +0000 Subject: Import openvswitch3.1-3.1.0-111 from Fast DataPath --- diff --git a/SOURCES/openvswitch-3.1.0.patch b/SOURCES/openvswitch-3.1.0.patch index 9108f34..171520f 100644 --- a/SOURCES/openvswitch-3.1.0.patch +++ b/SOURCES/openvswitch-3.1.0.patch @@ -10419,6 +10419,15 @@ diff --git a/python/build/soutil.py b/python/ovs_build_helpers/soutil.py similarity index 100% rename from python/build/soutil.py rename to python/ovs_build_helpers/soutil.py +diff --git a/python/test_requirements.txt b/python/test_requirements.txt +index 6aaee13e3f..6e96ce50b3 100644 +--- a/python/test_requirements.txt ++++ b/python/test_requirements.txt +@@ -1,3 +1,4 @@ ++packaging + pytest + netaddr + pyparsing diff --git a/rhel/usr_lib_systemd_system_ovsdb-server.service b/rhel/usr_lib_systemd_system_ovsdb-server.service index 49dc06e38c..558632320c 100644 --- a/rhel/usr_lib_systemd_system_ovsdb-server.service @@ -10440,6 +10449,53 @@ index 83b1cb3b48..3a8c459756 100644 /idltest.c /idltest.h /idltest.ovsidl +diff --git a/tests/atlocal.in b/tests/atlocal.in +index e02248f6f8..c35c394eda 100644 +--- a/tests/atlocal.in ++++ b/tests/atlocal.in +@@ -243,18 +243,35 @@ export UBSAN_OPTIONS + REQUIREMENT_PATH=$abs_top_srcdir/python/test_requirements.txt $PYTHON3 -c ' + import os + import pathlib +-import pkg_resources + import sys + ++PACKAGING = True ++try: ++ from packaging import requirements ++ from importlib import metadata ++except ModuleNotFoundError: ++ PACKAGING = False ++ import pkg_resources ++ + with pathlib.Path(os.path.join(os.getenv("REQUIREMENT_PATH"))).open() as reqs: +- for req in pkg_resources.parse_requirements(reqs): +- try: +- pkg_resources.require(str(req)) +- except pkg_resources.DistributionNotFound: +- sys.exit(2) ++ if PACKAGING: ++ for req in reqs.readlines(): ++ try: ++ r = requirements.Requirement(req.strip()) ++ if metadata.version(r.name) not in r.specifier: ++ raise metadata.PackageNotFoundError ++ except metadata.PackageNotFoundError: ++ sys.exit(2) ++ else: ++ for req in pkg_resources.parse_requirements(reqs): ++ try: ++ pkg_resources.require(str(req)) ++ except pkg_resources.DistributionNotFound: ++ sys.exit(2) + ' + case $? in + 0) HAVE_PYTEST=yes ;; + 2) HAVE_PYTEST=no ;; +- *) echo "$0: unexpected error probing Python unit test requirements" >&2 ;; ++ *) HAVE_PYTEST=no ++ echo "$0: unexpected error probing Python unit test requirements" >&2 ;; + esac diff --git a/tests/automake.mk b/tests/automake.mk index c8de3fe28d..e39453cd14 100644 --- a/tests/automake.mk diff --git a/SPECS/openvswitch3.1.spec b/SPECS/openvswitch3.1.spec index 088e639..d24f896 100644 --- a/SPECS/openvswitch3.1.spec +++ b/SPECS/openvswitch3.1.spec @@ -57,7 +57,7 @@ Summary: Open vSwitch Group: System Environment/Daemons daemon/database/utilities URL: http://www.openvswitch.org/ Version: 3.1.0 -Release: 110%{?dist} +Release: 111%{?dist} # Nearly all of openvswitch is ASL 2.0. The bugtool is LGPLv2+, and the # lib/sflow*.[ch] files are SISSL @@ -754,6 +754,13 @@ exit 0 %endif %changelog +* Thu May 23 2024 Open vSwitch CI - 3.1.0-111 +- Merging upstream branch-3.1 [RH git: 8dcf26eb16] + Commit list: + 738bc59942 atlocal: Replace deprecated pkg_resources. + 373f0ad878 atlocal: Fix setting HAVE_PYTEST on unexpected errors. + + * Fri May 17 2024 Open vSwitch CI - 3.1.0-110 - Merging upstream branch-3.1 [RH git: a475882723] Commit list: