Log unhandled exceptions and notify the user