Created
September 25, 2021 17:32
-
-
Save ricrogz/a5b8fd5c90b6b03cda9413dc8d6cb099 to your computer and use it in GitHub Desktop.
Python: run in subprocess
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import concurrent | |
with concurrent.futures.ProcessPoolExecutor(max_workers=1) as executor: | |
w = executor.submit(myfunc).result() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment