log errors in string form