code: def run(self, debug=False, reload=None):
          
          loop = asyncio.get_event_loop()
  
          logging.basicConfig(level=logging.DEBUG if debug else logging.INFO)
  
          if reload is None:
              reload = debug
  
          bot_loop = asyncio.ensure_future(self.loop())
  
          try:
              if reload:
                  loop.run_until_complete(run_with_reloader(loop, bot_loop, self.stop))
  
              else:
                  loop.run_until_complete(bot_loop)
  
          # User cancels
          except KeyboardInterrupt:
              logger.debug("User cancelled")
              bot_loop.cancel()
              self.stop()
  
          # Stop loop
          finally:
              if AIOHTTP_23:
                  loop.run_until_complete(self.session.close())
  
              logger.debug("Closing loop")
              loop.stop()
              loop.close()
docs: Convenience method for running bots in getUpdates mode
  
          :param bool debug: Enable debug logging and automatic reloading
          :param bool reload: Automatically reload bot on code change
          :Example:
  
          >>> if __name__ == '__main__':
          >>>     bot.run()