Explorar o código

Windows: Do not show maxtasks warning. Closes #1630

Ask Solem %!s(int64=11) %!d(string=hai) anos
pai
achega
1de8c5d9c0
Modificáronse 1 ficheiros con 2 adicións e 1 borrados
  1. 2 1
      celery/concurrency/prefork.py

+ 2 - 1
celery/concurrency/prefork.py

@@ -9,6 +9,7 @@
 from __future__ import absolute_import
 
 import os
+import sys
 
 from billiard import forking_enable
 from billiard.pool import RUN, CLOSE, Pool as BlockingPool
@@ -105,7 +106,7 @@ class TaskPool(BasePool):
         Will pre-fork all workers so they're ready to accept tasks.
 
         """
-        if self.options.get('maxtasksperchild'):
+        if self.options.get('maxtasksperchild') and sys.platform != 'win32':
             try:
                 from billiard.connection import Connection
                 Connection.send_offset