I have a script that creates a graph, but the script continues to run in the background until the window is closed, I would like it to leave as soon as the window was created, so that Ctrl-C in the shell will not kill the window, and so that the user can leave the window open and continue working in the shell without bg - manually. I saw some solutions with demons, but I would like this to not split into two scenarios. Is multiprocessing the easiest solution, or is there something shorter?
The corresponding show() command is the last thing the script runs, so I don't need to refer to the window in any way.
Edit: I do not want to save the shape as a file, I want to be able to use the interactive window. Essentially, this is the same as starting mian ... & in bash
source share