+ added priority to tasks
+ added error event for tasks