aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/python/grpcio_health_checking/commands.py
diff options
context:
space:
mode:
authorGravatar Masood Malekghassemi <soltanmm@users.noreply.github.com>2015-10-22 17:43:33 -0700
committerGravatar Masood Malekghassemi <soltanmm@users.noreply.github.com>2015-10-23 13:13:45 -0700
commit2a0cb49152a4adeeffd1ee707650d332e4dd37b5 (patch)
treefa2de875d35821002df62f684ac247b4a8638f62 /src/python/grpcio_health_checking/commands.py
parent7f5b3285b18d2b654a6ff8f3908314c1ad7fcd18 (diff)
Bring Python interop tests to the beta API
Also uses the .proto files for the service/stub definitions.
Diffstat (limited to 'src/python/grpcio_health_checking/commands.py')
-rw-r--r--src/python/grpcio_health_checking/commands.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/python/grpcio_health_checking/commands.py b/src/python/grpcio_health_checking/commands.py
index 6a95e679c4..3f4ea6e22f 100644
--- a/src/python/grpcio_health_checking/commands.py
+++ b/src/python/grpcio_health_checking/commands.py
@@ -50,7 +50,7 @@ class BuildProtoModules(setuptools.Command):
pass
def finalize_options(self):
- self.protoc_command = 'protoc'
+ self.protoc_command = distutils.spawn.find_executable('protoc')
self.grpc_python_plugin_command = distutils.spawn.find_executable(
'grpc_python_plugin')
@@ -69,7 +69,11 @@ class BuildProtoModules(setuptools.Command):
'--python_out={}'.format(root_directory),
'--python-grpc_out={}'.format(root_directory),
] + paths
- subprocess.check_call(' '.join(command), cwd=root_directory, shell=True)
+ try:
+ subprocess.check_output(' '.join(command), cwd=root_directory, shell=True,
+ stderr=subprocess.STDOUT)
+ except subprocess.CalledProcessError as e:
+ raise Exception('{}\nOutput:\n{}'.format(e.message, e.output))
class BuildPy(build_py.build_py):