simple methods to build a log output for errors and warnings