So I have some code that waits for X to happen, then creates a thread and does processEmail.
What I am looking for is a way for the code to carry on waiting X even though processEmail is happening in another thread but currently the code just waits for the thread to finish before waiting for X to happen again.
if X happens:
thread = Thread(target = processEmail.main())
thread.start()
FYI I have nothing that requires the output of processEmail.main() further down the code therefore there is no need for me to wait for its output.