def __eq__(self, other):
        return (isinstance(other, self.__class__) and
                other.package == self.package)
def deserialize(self, value):
        value = decode(value)
        validators.validate_choice(value.lower(), self.levels.keys())
        return self.levels.get(value.lower())