mirror of
https://github.com/django-q2/django-q2.git
synced 2026-10-07 23:18:11 +08:00
Fix cluster requesting hardcoded unix-only fork context (#347)
This commit is contained in:
+4
-1
@@ -41,7 +41,10 @@ from django_q.worker import worker
|
||||
|
||||
|
||||
def get_mp_context():
|
||||
return multiprocessing.get_context("fork")
|
||||
if "fork" in multiprocessing.get_all_start_methods():
|
||||
return multiprocessing.get_context("fork")
|
||||
else:
|
||||
return multiprocessing.get_context()
|
||||
|
||||
|
||||
class Cluster:
|
||||
|
||||
Reference in New Issue
Block a user