From d22861349828a9cbb9e8f41b5a5a7668c4b466c8 Mon Sep 17 00:00:00 2001 From: Martin Mirchev Date: Mon, 9 Dec 2024 13:33:35 +0800 Subject: [PATCH] Keep behavior consistent across platforms --- app/main.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/app/main.py b/app/main.py index 96d4dea6..293f0bcd 100644 --- a/app/main.py +++ b/app/main.py @@ -4,6 +4,8 @@ import json import logging +from multiprocessing import set_start_method +import platform import shutil from argparse import ArgumentParser from collections.abc import Mapping, Sequence @@ -646,6 +648,9 @@ def dump_cost( if __name__ == "__main__": + if platform.system() == "Darwin": + #Macos specific requirement for Multi-Processing + set_start_method('fork',force=True) logging.getLogger("httpx").setLevel(logging.WARNING) logger.remove() main()