improve error message for tags missing type