Better error logging.