Browse Source

Don't use cached detect_environment

Ask Solem 12 năm trước cách đây
mục cha
commit
158d62c631
1 tập tin đã thay đổi với 2 bổ sung2 xóa
  1. 2 2
      celery/utils/threads.py

+ 2 - 2
celery/utils/threads.py

@@ -13,7 +13,7 @@ import sys
 import threading
 import traceback
 
-from kombu.syn import detect_environment
+from kombu.syn import _detect_environment
 
 from celery.local import Proxy
 
@@ -318,7 +318,7 @@ class _FastLocalStack(threading.local):
         except (AttributeError, IndexError):
             return None
 
-if detect_environment() == 'default' and not USE_PURE_LOCALS:
+if _detect_environment() == 'default' and not USE_PURE_LOCALS:
     LocalStack = _FastLocalStack
 else:
     # - See #706