print reason of error