Avoid Celery retries for unregistered task

Celery is not doing anything to actively retry the task. As the message states, the task is ignored. The task has been queued and, reasonably, celery won't remove it from the queue unless it actually executes a task associated with the message. The behavior you observe is correct and desirable.

You wouldn't want to have the receipt of an unregistered task cause the message to be removed from the queue because that could result in loss of messages. For example, if you deploy a new version of your app with a new task, but an old worker is still active (which happens with virtually all zero-downtime deployments) the old version can pick up messages from the new version and it will believe it has picked up an unregistered task. If you celery were to remove messages when it encountered unregistered tasks, this could result in loss of these messages, among other similar cases.

Some possible options within the celery framework:

Hook into task rejection signals

The consumer will fire the task rejected signal when the task is rejected. You could use this to hook into the event and do something (maybe use SQS API to move the message).

Customize the consumer

The celery consumer controls the behavior in this case in the on_unknown_task method. You could subclass and extend the consumer to control the behavior.