Let\'s say I want to be able to log to file every time any exception is raised, anywhere in my program. I don\'t want to modify any existing code.
Of course, this c
If you want to log uncaught exceptions, just use sys.excepthook.
I'm not sure I see the value of logging all raised exceptions, since lots of libraries will raise/catch exceptions internally for things you probably won't care about.