I am trying to make it so all uncaught exception are logged to file without having to put a try/catch block around each of my scripts.
At the moment, I have made a module that I import into all scripts. I would like to be able in this module to run some python that would catch uncaught exceptions.
I have read about the module atexit, but it's not quite what I need, I think. However there might be something I'm not aware of in this module?
I need to do that because I run my scripts via the Task Scheduler, and this gives you only error code, not anything helpful like a stacktrace