def validate_attr(self, append):
if append:<EOL><INDENT>existing_fields = getattr(self.attrs, self.kind_attr, None)<EOL>if (existing_fields is not None and<EOL>existing_fields != list(self.values)):<EOL><INDENT>raise ValueError("<STR_LIT>"<EOL>"<STR_LIT>")<EOL><DEDENT>existing_dtype = getattr(self.attrs, self.dtype_attr, None)<EOL>if (existing_dtype is not None and<EOL>existing_dtype != self.dtype):<EOL><INDENT>raise ValueError("<STR_LIT>"<EOL>"<STR_LIT>")<EOL><DEDENT><DEDENT>
validate that we have the same order as the existing & same dtype