:param Task|callable task: Remove 'task' from the list of tasks to run periodically

def remove_task(cls, task):
        """
        :param Task|callable task: Remove 'task' from the list of tasks to run periodically
        """
        with cls._lock:
            if not isinstance(task, Task):
                task = cls.resolved_task(task)

            if task:
                cls.tasks.remove(task)

            cls.tasks.sort()