Explorar el Código

Fix Python 3 issue.

Ionel Cristian Mărieș hace 11 años
padre
commit
4e79739b99
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      celery/concurrency/workhorse.py

+ 1 - 1
celery/concurrency/workhorse.py

@@ -76,7 +76,7 @@ class Workhorse(object):
     _children = ()
 
     def __init__(self, target, args, kwargs):
-        self._name = self.name = 'Workhorse-%s' % Workhorse._counter.next()
+        self._name = self.name = 'Workhorse-%s' % next(Workhorse._counter)
         sys.stdout.flush()
         sys.stderr.flush()
         self.pid = os.fork()