improved logging catches