    def alert_user(self, user, task):
        # type: (User, Task) -> None
        '''
        Alerts a user about an alert that was trigged and associated with their
        name.

        Args:
            user (User): The user associated with the task.
            task (Task): A task to alert on.
        '''
        # Format the reason to be indented
        reason = '\n'.join(['>' + s for s in task.reason.split('\n')])

        message = self.messages['alert'].format(task.description, reason)
        message += '\n'
        message += self.messages['action_prompt']
        self.chat.message_user(user, message)
Alerts a user about an alert that was trigged and associated with their
name.

Args:
user (User): The user associated with the task.
task (Task): A task to alert on.
securitybot/bot.py