code: def run(self):
          
          def render(results=[], error=None):
              if len(results) and not results[0].timed_out:
                  self.render(results)
              elif error:
                  self.do_render(error=error)
  
          # start the client
          self.client.start(self.build_requests, render)
  
          # handle keyboard input
          try:
              with self.t.cbreak():
                  val = ''
                  while not self.done:
                      val = self.t.inkey(timeout=1)
                      if val:
                          self.handle_key(val)
          except KeyboardInterrupt:
              self.exit()
docs: Run the view event loop.