Przeglądaj źródła

Windows: Do not show maxtasks warning. Closes #1630

Ask Solem 11 lat temu
rodzic
commit
1de8c5d9c0
1 zmienionych plików z 2 dodań i 1 usunięć
  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