force fork on Linux, fixes #1843

This commit is contained in:
Jay Lee
2025-10-08 13:55:34 +00:00
parent 6db2309fc4
commit 072dc4809a

View File

@@ -34,7 +34,10 @@ def main():
# Run from command line
if __name__ == '__main__':
if platform.system() != 'Linux':
multiprocessing.freeze_support()
multiprocessing.freeze_support()
if platform.system() == 'Linux':
# no longer default in Python 3.14+ so we set it.
multiprocessing.set_start_method('fork')
else:
multiprocessing.set_start_method('spawn')
main()