text: import asyncio
  from concurrent.futures import ThreadPoolExecutor
  import functools
  import time
  
  import grpc
  
  import service_pb2
  import service_pb2_grpc
  
  
  _executor = ThreadPoolExecutor(1)
  
  
  def _submit(func, *args):
      func_partial = functools.partial(func, *args)
      return loop.run_in_executor(_executor, func_partial)
  
  
  async def main():
  
      with grpc.insecure_channel('localhost:50001') as channel:
          stub = service_pb2_grpc.ServerStub(channel)
  
          print('Send request')
          await _submit(stub.Foo, service_pb2.Empty())
  
          print('Request successful')
  
  
  if __name__ == '__main__':
      loop = asyncio.get_event_loop()
      loop.run_until_complete(main())
      loop.close()
  