docs: def set_timer(self, duration):
          """Setup the next alarm to fire and then wait for it to fire.
  
          :param int duration: How long to sleep
  
          """
          # Make sure that the application is not shutting down before sleeping
          if self.is_shutting_down:
              LOGGER.debug('Not sleeping, application is trying to shutdown')
              return
  
          # Set the signal timer
          signal.setitimer(signal.ITIMER_REAL, duration, 0)