Can I exit PyCharm and run it again automatically?

I have a test script that runs for hours in a loop using Selenium and Google Chrome driver. The initial run time is about 80 minutes, but if I leave it run in a loop for a day, at the end of the day the run time is close to five hours. However, at any time if I just exit PyCharm and start it again, the run time goes back to 80 minutes. Is there a way to exit PyCharm automatically right after my script finishes and then run PyCharm again to execute the same script?

Please sign in to leave a comment.