Explorar o código

Pass args and kwargs to the context when called locally

Dmitry Malinovsky %!s(int64=10) %!d(string=hai) anos
pai
achega
21bdfd5008
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      celery/app/task.py

+ 1 - 1
celery/app/task.py

@@ -319,7 +319,7 @@ class Task(object):
 
     def __call__(self, *args, **kwargs):
         _task_stack.push(self)
-        self.push_request()
+        self.push_request(args=args, kwargs=kwargs)
         try:
             # add self if this is a bound task
             if self.__self__ is not None: