def _build_attribute_modifiers(var, attribute_mapping, ignore=None):
if not isinstance(ignore, list):<EOL><INDENT>ignore = ["<STR_LIT:type>", "<STR_LIT:name>", "<STR_LIT>", "<STR_LIT:default>"]<EOL><DEDENT>if not is_config_var(var):<EOL><INDENT>raise ValueError(<EOL>f"<STR_LIT>"<EOL>)<EOL><DEDENT>entry = var.metadata[CONFIG_KEY]<EOL>modifiers = {}<EOL>for (entry_attribute, entry_value) in zip(<EOL>attr.fields(type(entry)), attr.astuple(entry)<EOL>):<EOL><INDENT>if entry_value is not None:<EOL><INDENT>if entry_attribute.name in ignore:<EOL><INDENT>continue<EOL><DEDENT>elif entry_attribute.name in attribute_mapping:<EOL><INDENT>if entry_attribute.type is not None and (<EOL>type(entry_value) in entry_attribute.type<EOL>if isinstance(entry_attribute.type, (list, tuple, set))<EOL>else type(entry_value) == entry_attribute.type<EOL>):  <EOL><INDENT>modifiers[attribute_mapping[entry_attribute.name]] = entry_value<EOL><DEDENT>else:<EOL><INDENT>raise ValueError(<EOL>f"<STR_LIT>"<EOL>f"<STR_LIT>"<EOL>f"<STR_LIT>"<EOL>)<EOL><DEDENT><DEDENT>else:<EOL><INDENT>warnings.warn(<EOL>f"<STR_LIT>"<EOL>f"<STR_LIT>"<EOL>)<EOL><DEDENT><DEDENT><DEDENT>return modifiers<EOL>
Handles adding schema modifiers for a given config var and some mapping.

    :param attr._make.Attribute var: The config var to build modifiers for
    :param Dict[str, str] attribute_mapping: A mapping of attribute to jsonschema
        modifiers
    :param List[str] ignore: A list of mapping keys to ignore, defaults to None
    :raises ValueError: When the given ``var`` is not an config var
    :raises ValueError: When jsonschema modifiers are given the wrong type
    :return: A dictionary of the built modifiers
    :rtype: Dict[str, Any]