Beispiel #1
0
 def run(self):
   # due to limitations of the proto generator, we require that only *one*
   # directory is provided as an 'include' directory. We assume it's the '' key
   # to `self.distribution.package_dir` (and get a key error if it's not
   # there).
   from grpc.tools import command
   command.build_package_protos(self.distribution.package_dir[''])
Beispiel #2
0
 def _compile_proto_files(self, variables):
     """
     Compile .proto resource into the definition (_pb2) and client code (_pb2_grpc)
     """
     from grpc.tools import command
     schema = fill_template(self.schema, variables)
     command.build_package_protos(join(variables['RESOURCES_DIR'],
                                       dirname(schema)),
                                  strict_mode=True)
Beispiel #3
0
 def setUp(self):
     super().setUp()
     file_utils.ensure_empty(
         join(test.get_test_dir(self.test_name), 'private_resource'))
     self.copy_resource('calculator.py')
     self.copy_resource('calculator.proto')
     self.copy_resource('greeter.py')
     self.copy_resource('greeter.proto')
     from grpc.tools import command
     command.build_package_protos(join(test.get_test_dir(self.test_name),
                                       'private_resource'),
                                  strict_mode=True)
 def run(self):
     install.run(self)
     from grpc.tools import command
     command.build_package_protos('')
 def build_package_protos(self):
     from grpc.tools import command
     command.build_package_protos(self.distribution.package_dir[''])
Beispiel #6
0
 def run(self):
     install.run(self)
     from grpc.tools import command
     command.build_package_protos(self.distribution.package_dir[''])
Beispiel #7
0
def build_protos():
    SETUP_DIR = os.path.dirname(os.path.abspath(__file__))
    from grpc.tools import command
    command.build_package_protos(SETUP_DIR)
Beispiel #8
0
 def run(self):
     from grpc.tools import command
     command.build_package_protos('./dellve_benchend/dellve_proto/')