[Answer]-Pass parameter request to a celery task in Django


This does not work with the standard pickler. See more here (basically a duplicate): passing django request object to celery task


As you can read from the docs your example should work.

from celery import task

def add(x, y):
    return x + y

add.delay(2, 2)


This should work as long as you’re using standard pickle serializer.

Leave a comment