Replace task.str_status with str(task.status)