Browse Source

[Re-Fix] Protocol shadow exception when self.__self__ is None (Erase with merge #dffb61c)

PMickael 9 years ago
parent
commit
8fc32a5824
1 changed files with 2 additions and 1 deletions
  1. 2 1
      celery/app/task.py

+ 2 - 1
celery/app/task.py

@@ -471,13 +471,14 @@ class Task(object):
         if self.__self__ is not None:
             args = args if isinstance(args, tuple) else tuple(args or ())
             args = (self.__self__, ) + args
+            shadow = shadow or self.shadow_name(args, kwargs, final_options)
 
         preopts = self._get_exec_options()
         options = dict(preopts, **options) if options else preopts
         return app.send_task(
             self.name, args, kwargs, task_id=task_id, producer=producer,
             link=link, link_error=link_error, result_cls=self.AsyncResult,
-            shadow=shadow or self.shadow_name(args, kwargs, options),
+            shadow=shadow,
             **options
         )