From 0e24177fc3966c2951b45e432620a549dfd5419a Mon Sep 17 00:00:00 2001 From: Richard Belleville Date: Wed, 9 Sep 2020 15:32:52 -0700 Subject: [PATCH] Make version check more stringent --- tools/distrib/python/grpcio_tools/grpc_tools/protoc.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/distrib/python/grpcio_tools/grpc_tools/protoc.py b/tools/distrib/python/grpcio_tools/grpc_tools/protoc.py index 50789d79940..e03acb69f9d 100644 --- a/tools/distrib/python/grpcio_tools/grpc_tools/protoc.py +++ b/tools/distrib/python/grpcio_tools/grpc_tools/protoc.py @@ -38,7 +38,8 @@ def main(command_arguments): return _protoc_compiler.run_main(command_arguments) -if sys.version_info[0] > 2: +# NOTE(rbellevi): importlib.abc is not supported on 3.4. +if sys.version_info >= (3, 5, 0): import contextlib import importlib import importlib.machinery