We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 87df897 commit 4f9f1aeCopy full SHA for 4f9f1ae
taskiq/cli/worker/run.py
@@ -2,7 +2,9 @@
2
import logging
3
import signal
4
from concurrent.futures import ThreadPoolExecutor
5
+from multiprocessing import set_start_method
6
from multiprocessing.synchronize import Event
7
+from sys import platform
8
from typing import Any, Type
9
10
from taskiq.abc.broker import AsyncBroker
@@ -158,6 +160,8 @@ def run_worker(args: WorkerArgs) -> None: # noqa: WPS213
158
160
159
161
:raises ValueError: if reload flag is used, but dependencies are not installed.
162
"""
163
+ if platform == "darwin":
164
+ set_start_method("fork")
165
if args.configure_logging:
166
logging.basicConfig(
167
level=logging.getLevelName(args.log_level),
0 commit comments