def search_entries(module_list, ops = None, constructors = None, seen = None):
    if ops is None: ops = []
    if constructors is None: constructors = []
    if seen is None: seen = set()
    modules = []

    for module in module_list:
        symbol_name_list = [s for s in dir(module) if not s[0] == '_']
        
        for symbol_name in symbol_name_list:
            symbol = getattr(module, symbol_name)
            try:
                if symbol in seen:
                    continue
                seen.add(symbol)
            except __HOLE__:
                pass
            if type(symbol) == type(module): # module
                modules.append(symbol)
            try:
                ops.append(EntryOp(symbol, symbol_name, module))
            except TypeError:
                try:
                    constructors.append(EntryConstructor(symbol, symbol_name, module))
                except TypeError:
                    pass

    for symbol in modules:
        search_entries([symbol], ops, constructors, seen)

    return ops, constructors
dataset/ETHPy150Open RDFLib/rdfextras/docs/scripts/gen_oplist.py/search_entries