Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #wait_five_seconds.py
- import time
- print("About to sleep.")
- time.sleep(5)
- print("Done sleeping.")
- #main.py
- import subprocess
- print("About to call child.")
- subprocess.run([r"C:\Programming\Python 3.8\sample_venv\Scripts\python.exe", "wait_five_seconds.py"])
- print("Done calling.")
- """
- result:
- About to call child.
- About to sleep.
- Done sleeping.
- Done calling.
- """
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement