NoReverseMatch error in django

I am learning django. My URL pattern is like below.

path('task-delete/<int:pk>/', DeleteView.as_view(), name="tasks-delete"),

I have class based view like below.

class DeleteView(DeleteView):
    model = Task
    context_object_name = 'task'
    success_url = reverse_lazy('tasks')

HTML code in template is like below.

<a href="{%  url 'task-delete' task.pk %}">Delete</a>

My error is like below.

enter image description here

How to fix this error ?

The error message is quite explicit here. You do not have a url named ‘task-delete’.

You have a url named ‘tasks-delete’, but that is not the same.