wfDebugLog exception if thrown during formatting

Some exception is not loggable, which won't be logged by
MWExceptionhandler::logException(), we should log it in
the debug log for debugging purpose

Change-Id: I709c45f7e47afacb98be3a869eb5b70660e18f48