From e41e41e209d395b04b755af15cc36448fe6fb06b Mon Sep 17 00:00:00 2001 From: Richard Belleville Date: Wed, 22 Feb 2023 09:40:48 -0800 Subject: [PATCH] Remove protobuf 4.22.0 from testing (#32442) This version broke backward compatibility in `plugin_pb2.py`, which is presumably a relatively minor regression, since we have not yet heard any complaints about it. This PR: - Excludes `4.22.0` from installation - _Includes_ protobuf pre-releases into testing so this can be caught more quickly in the future. When bad prereleases are caught, we can exclude them from testing in a similar manner to this PR. We may eventually want to invest into a system where we can define these bad versions centrally. --- src/python/grpcio_tests/setup.py | 4 ++-- tools/run_tests/helper_scripts/build_python.sh | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/python/grpcio_tests/setup.py b/src/python/grpcio_tests/setup.py index edaae29e594..fbf2e3835fd 100644 --- a/src/python/grpcio_tests/setup.py +++ b/src/python/grpcio_tests/setup.py @@ -42,8 +42,8 @@ INSTALL_REQUIRES = ( 'grpcio-status>={version}'.format(version=grpc_version.VERSION), 'grpcio-tools>={version}'.format(version=grpc_version.VERSION), 'grpcio-health-checking>={version}'.format(version=grpc_version.VERSION), - 'oauth2client>=1.4.7', 'protobuf>=4.21.6', 'google-auth>=1.17.2', - 'requests>=2.14.2') + 'oauth2client>=1.4.7', 'protobuf>=4.21.6rc1,!=4.22.0.*', + 'google-auth>=1.17.2', 'requests>=2.14.2') COMMAND_CLASS = { # Run `preprocess` *before* doing any packaging! diff --git a/tools/run_tests/helper_scripts/build_python.sh b/tools/run_tests/helper_scripts/build_python.sh index 1a26cdcc6c6..4f40fe7b438 100755 --- a/tools/run_tests/helper_scripts/build_python.sh +++ b/tools/run_tests/helper_scripts/build_python.sh @@ -165,7 +165,7 @@ pip_install_dir_and_deps() { pip_install -U gevent pip_install --upgrade cython -pip_install --upgrade six protobuf>=4.21.3 +pip_install --upgrade six 'protobuf>=4.21.3rc1,!=4.22.0.*' if [ "$("$VENV_PYTHON" -c "import sys; print(sys.version_info[0])")" == "2" ] then