Finding the name of the program from which a Python module is running can be trickier than it would seem at first, so lets make it damned easy. This works under pycharm, pytest, pytest-docrunner, ...