beam-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rober...@apache.org
Subject [1/2] beam git commit: Catch subprocess error in proto generation.
Date Tue, 26 Sep 2017 20:40:17 GMT
Repository: beam
Updated Branches:
  refs/heads/master 2aa3b5c69 -> 732ae4297


Catch subprocess error in proto generation.

Project: http://git-wip-us.apache.org/repos/asf/beam/repo
Commit: http://git-wip-us.apache.org/repos/asf/beam/commit/6dcdea74
Tree: http://git-wip-us.apache.org/repos/asf/beam/tree/6dcdea74
Diff: http://git-wip-us.apache.org/repos/asf/beam/diff/6dcdea74

Branch: refs/heads/master
Commit: 6dcdea7422290c36e19c59bf70b4f89d601f6af4
Parents: 2aa3b5c
Author: Robert Bradshaw <robertwb@gmail.com>
Authored: Tue Sep 26 13:17:14 2017 -0700
Committer: GitHub <noreply@github.com>
Committed: Tue Sep 26 13:17:14 2017 -0700

----------------------------------------------------------------------
 sdks/python/gen_protos.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/beam/blob/6dcdea74/sdks/python/gen_protos.py
----------------------------------------------------------------------
diff --git a/sdks/python/gen_protos.py b/sdks/python/gen_protos.py
index a3d963d..e3da0e7 100644
--- a/sdks/python/gen_protos.py
+++ b/sdks/python/gen_protos.py
@@ -81,6 +81,8 @@ def generate_proto_files():
           target=_install_grpcio_tools_and_generate_proto_files)
       p.start()
       p.join()
+      if p.exitcode:
+        raise ValueError("Proto generation failed (see log for details).")
     else:
       logging.info('Regenerating out-of-date Python proto definitions.')
       builtin_protos = pkg_resources.resource_filename('grpc_tools', '_proto')
@@ -122,4 +124,4 @@ def _install_grpcio_tools_and_generate_proto_files():
 
 
 if __name__ == '__main__':
-  generate_proto_files()
\ No newline at end of file
+  generate_proto_files()


Mime
View raw message