Guest User

Untitled

a guest
Jul 16th, 2020
10
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #wait_five_seconds.py
  2. import time
  3. print("About to sleep.")
  4. time.sleep(5)
  5. print("Done sleeping.")
  6.  
  7. #main.py
  8. import subprocess
  9. print("About to call child.")
  10. subprocess.run([r"C:\Programming\Python 3.8\sample_venv\Scripts\python.exe", "wait_five_seconds.py"])
  11. print("Done calling.")
  12.  
  13. """
  14. result:
  15. About to call child.
  16. About to sleep.
  17. Done sleeping.
  18. Done calling.
  19. """
RAW Paste Data