Most people assume object tracking for autonomous flight is very complex, but it doesn’t have to be that way. All you need is ...
detect_shell pokes around the process's running environment to determine what shell it is run in. It returns a 2-tuple: The shell name, always lowercased. The command used to run the shell.