docs: def run(self):
  		"""
  		Calls the defined action every $interval seconds. Optionally calls an action before
  		the main loop, and an action when stopping, if these are defined.
  
  		Exceptions in the main loop will NOT cause the thread to die.
  		"""
  		self.logger.debug("Thread {0} is entering main loop".format(self.name))
  
  		if hasattr(self, "init_action"):
  			self.logger.debug("Thread {0} is calling its init action")
  			self.init_action(*self.init_args, **self.init_kwargs)
  
  		while not self.stop:
  			self.logger.debug("Delay is {0}".format(self.delay))
  			if (datetime.datetime.now() - self.lastRun).total_seconds() > self.delay:
  				self.logger.debug("Thread {0} is running".format(self.name))
  				try:
  					self.main_action(*self.main_args, **self.main_kwargs)
  				except Exception:
  					self.logger.exception("Thread {0} generated an exception!".format(self.name))
  
  				self.lastRun = datetime.datetime.now()
  				self.logger.debug("Thread {0} is done".format(self.name))
  			time.sleep(1)
  
  		if hasattr(self, "stop_action"):
  			self.logger.debug("Thread {0} is calling its stop action")
  			self.stop_action(*self.stop_args, **self.stop_kwargs)
  
  		self.logger.debug("Thread {0} is exiting main loop".format(self.name))