kliment / Printrun

Pronterface, Pronsole, and Printcore - Pure Python 3d printing host software
GNU General Public License v3.0
2.38k stars 997 forks source link

Make the print thread in the printcore code a background thread (daemon) #1179

Open ckasarda opened 3 years ago

ckasarda commented 3 years ago

Would it be possible for the print thread in printcore.py to be changed to a daemonized thread, like with the startprint function? It would be nice if started the print command in the background instead and then run after the application is closed. Thanks! Otherwise, would there be a conflict that would emerge by doing so?

It would also be nice if the print start function had another boolean argument as to whether the user wanted to daemonize the print start thread or not. Would this be possible?

volconst commented 3 years ago

How do you start the process? Is it by the provided source or from your own class? Running in background will make it harder to interact with it (e.g control-c). Can't you start a new thread yourself or tell the shell to put it to background with (& ending)?