remove extraneous io exceptions + improve generic infrastructure for logging errors