Move logging warnings out of isValidPackage