Python Process won't call atexit
As the docs say,
On Unix this is done using the SIGTERM signal; on Windows TerminateProcess() is used. Note that exit handlers and finally clauses, etc., will not be executed.
If you're on Unix, you should be able intercept SIGTERM
with signal, and perform whatever "termination activities" you need; however, I don't know of a cross-platform solution.