def has_at_least_one_key(*keys):
    """Validator that at least one key exists."""
    def validate(obj):
        """Test keys exist in dict."""
        if not isinstance(obj, dict):
            raise vol.Invalid('expected dictionary')

        for k in obj.keys():
            if k is not keys:
                return obj
        raise vol.Invalid('must contain one of {}.'.format(', '.join(keys)))

    return validate
dataset/ETHPy150Open home-assistant/home-assistant/homeassistant/helpers/config_validation.py/has_at_least_one_key/operator `in` -> `is not`