Improve error reporting for Crash on Exit
Many things done in a Python plugin can cause a C++ crash on exit. Fixing the crash is VERY difficult, as it happens once Python is finished so it can’t be caught by a Python Debugger or log message. The crash dialog on exit gives no hints as to what caused the crash, and the painter log doesn’t either. We need a way to know what from our scripting is crashing C++ on exit. This often occurs with events, connections, and UI elements. The only way to figure out what is causing the crash is bisecting your scripts line by line which is incredibly time consuming.