Here is a simple GNU parallel command that creates a file called “example_i.txt” inside an existing directory called “example_i”. It does this four times, for i from 1 to 4, with one job per core: Not very exciting, I know. The problem appears when I try to run this via python (v3.9) using the subprocess module as follows: When doing
Tag: gnu-parallel
GNU Parallel and Python atexit
I was trying to run a python script with GNU parallel. Everything seems to work, except for the atexit routine used inside the python script. It seems, after ctrl+c, parallel is killing the python process without giving python a chance to call the registered atexit routine. How to make parallel a bit nicer towards the child processes? Here is an