def noexpand_parse_cfgstrs(cfgopt_strs, alias_keys=None):
    r"""
    alias_keys = None
    cfgopt_strs = 'f=2,c=[(1,2),(3,4)],d=1'
    string  = cfgopt_strs

    cfgopt_strs = 'f=2,c=[1,2,3,4]'

    CommandLine:
        python -m utool.util_gridsearch noexpand_parse_cfgstrs

    Example:
        >>> # ENABLE_DOCTEST
        >>> from utool.util_gridsearch import *  # NOQA
        >>> import utool as ut
        >>> cfgopt_strs = 'b=[1,2]'
        >>> alias_keys = None
        >>> cfg_combo = noexpand_parse_cfgstrs(cfgopt_strs, alias_keys)
        >>> result = ('cfg_combo = %s' % (ut.repr2(cfg_combo, nl=0),))
        >>> print(result)
        cfg_combo = {'b': [1, 2]}
    """
    import re
    import utool as ut
    # Parse dict out of a string
    #ANYTHING_NOT_BRACE = r'[^\[\]]*\]'
    #NOT_PAREN_OR_BRACE = r'[^()\[\]]*'
    if True:
        # Use a proper parser
        cfg_options = parse_cfgstr3(cfgopt_strs)
    else:
        not_paren_or_brace = '[^' + re.escape('()[]') + ']'
        end_paren_or_brace = '[' + re.escape(')]') + ']'
        nested_pat = not_paren_or_brace + '*' + end_paren_or_brace
        split_pat = r',\s*' + ut.negative_lookahead(nested_pat)
        cfgstr_options_list = re.split(split_pat, cfgopt_strs)

        cfg_options = ut.parse_cfgstr_list(
            cfgstr_list=cfgstr_options_list, smartcast=True, oldmode=False)
    # Remap keynames based on aliases
    if alias_keys is not None:
        # Use new standard keys and remove old aliased keys
        for key in set(alias_keys.keys()):
            if key in cfg_options:
                cfg_options[alias_keys[key]] = cfg_options[key]
                del cfg_options[key]
    return cfg_options
def noexpand_parse_cfgstrs ( cfgopt_strs , alias_keys = None ) : import re import utool as ut if True : cfg_options = parse_cfgstr3 ( cfgopt_strs ) else : not_paren_or_brace = '[^' + re . escape ( '()[]' ) + ']' end_paren_or_brace = '[' + re . escape ( ')]' ) + ']' nested_pat = not_paren_or_brace + '*' + end_paren_or_brace split_pat = r',\s*' + ut . negative_lookahead ( nested_pat ) cfgstr_options_list = re . split ( split_pat , cfgopt_strs ) cfg_options = ut . parse_cfgstr_list ( cfgstr_list = cfgstr_options_list , smartcast = True , oldmode = False ) if alias_keys is not None : for key in set ( alias_keys . keys ( ) ) : if key in cfg_options : cfg_options [ alias_keys [ key ] ] = cfg_options [ key ] del cfg_options [ key ] return cfg_options
r"""
    alias_keys = None
    cfgopt_strs = 'f=2,c=[(1,2),(3,4)],d=1'
    string  = cfgopt_strs

    cfgopt_strs = 'f=2,c=[1,2,3,4]'

    CommandLine:
        python -m utool.util_gridsearch noexpand_parse_cfgstrs

    Example:
        >>> # ENABLE_DOCTEST
        >>> from utool.util_gridsearch import *  # NOQA
        >>> import utool as ut
        >>> cfgopt_strs = 'b=[1,2]'
        >>> alias_keys = None
        >>> cfg_combo = noexpand_parse_cfgstrs(cfgopt_strs, alias_keys)
        >>> result = ('cfg_combo = %s' % (ut.repr2(cfg_combo, nl=0),))
        >>> print(result)
        cfg_combo = {'b': [1, 2]}