(self, name, is_conditional)
Logs the start of each task
Logs the start of each task
Logs the start of each task
def playbook_on_task_start(self, name, is_conditional):
        """
        Logs the start of each task
        """

        if os.getenv("ANSIBLE_PROFILE_DISABLE") is not None:
            return

        if self.current is not None:
            # Record the running time of the last executed task
            self.stats[self.current] = time.time() - self.stats[self.current]

        # Record the start time of the current task
        self.current = name
        self.stats[self.current] = time.time()
def playbook_on_task_start ( self , name , is_conditional ) : if os . getenv ( "ANSIBLE_PROFILE_DISABLE" ) is not None : return if self . current is not None : # Record the running time of the last executed task self . stats [ self . current ] = time . time ( ) - self . stats [ self . current ] # Record the start time of the current task self . current = name self . stats [ self . current ] = time . time ( )