def _get_args(info):
    'Return the list of args & kwds for building the __init__ function'
    required = set()
    kwds = set()
    invalid_kwds = set()
    if info.is_allOf():
        arginfo = [_get_args(child) for child in info.allOf]
        nonkeyword = all((args[0] for args in arginfo))
        required = set.union(set(), *(args[1] for args in arginfo))
        kwds = set.union(set(), *(args[2] for args in arginfo))
        kwds -= required
        invalid_kwds = set.union(set(), *(args[3] for args in arginfo))
        additional = all((args[4] for args in arginfo))
    elif (info.is_empty() or info.is_compound()):
        nonkeyword = True
        additional = True
    elif info.is_value():
        nonkeyword = True
        additional = False
    elif info.is_object():
        invalid_kwds = ({p for p in info.required if (not is_valid_identifier(p))} | {p for p in info.properties if (not is_valid_identifier(p))})
        required = {p for p in info.required if is_valid_identifier(p)}
        kwds = {p for p in info.properties if is_valid_identifier(p)}
        kwds -= required
        nonkeyword = False
        additional = True
    else:
        raise ValueError('Schema object not understood')
    return (nonkeyword, required, kwds, invalid_kwds, additional)
Return the list of args & kwds for building the __init__ function
def _get_args(info):
    
    required = set()
    kwds = set()
    invalid_kwds = set()
    if info.is_allOf():
        arginfo = [_get_args(child) for child in info.allOf]
        nonkeyword = all((args[0] for args in arginfo))
        required = set.union(set(), *(args[1] for args in arginfo))
        kwds = set.union(set(), *(args[2] for args in arginfo))
        kwds -= required
        invalid_kwds = set.union(set(), *(args[3] for args in arginfo))
        additional = all((args[4] for args in arginfo))
    elif (info.is_empty() or info.is_compound()):
        nonkeyword = True
        additional = True
    elif info.is_value():
        nonkeyword = True
        additional = False
    elif info.is_object():
        invalid_kwds = ({p for p in info.required if (not is_valid_identifier(p))} | {p for p in info.properties if (not is_valid_identifier(p))})
        required = {p for p in info.required if is_valid_identifier(p)}
        kwds = {p for p in info.properties if is_valid_identifier(p)}
        kwds -= required
        nonkeyword = False
        additional = True
    else:
        raise ValueError('Schema object not understood')
    return (nonkeyword, required, kwds, invalid_kwds, additional)