Mitigate crashes while doing changes - more refined

This is a more refined version of my previous commit that also allows to show the errors in the Log if you allow to see Preview Errors in the yaf_export.py