diff options
Diffstat (limited to 'examples/python/helloworld/greeter_client.py')
-rw-r--r-- | examples/python/helloworld/greeter_client.py | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/examples/python/helloworld/greeter_client.py b/examples/python/helloworld/greeter_client.py index d9b2bdfd07..a0aeb47bd7 100644 --- a/examples/python/helloworld/greeter_client.py +++ b/examples/python/helloworld/greeter_client.py @@ -11,7 +11,6 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. - """The Python implementation of the GRPC helloworld.Greeter client.""" from __future__ import print_function @@ -23,11 +22,11 @@ import helloworld_pb2_grpc def run(): - channel = grpc.insecure_channel('localhost:50051') - stub = helloworld_pb2_grpc.GreeterStub(channel) - response = stub.SayHello(helloworld_pb2.HelloRequest(name='you')) - print("Greeter client received: " + response.message) + channel = grpc.insecure_channel('localhost:50051') + stub = helloworld_pb2_grpc.GreeterStub(channel) + response = stub.SayHello(helloworld_pb2.HelloRequest(name='you')) + print("Greeter client received: " + response.message) if __name__ == '__main__': - run() + run() |