Currently, the email notifications are only sent for scheduled tasks. If a task was triggered by some other way besides the scheduler and failed, no notification is sent automatically.
I solved it by listing all task details with ems-cmd filtering the tasks with a status Failed en sending an email using email action if there are failed tasks.