def METHOD_NAME(dirnames: list[str]):
    # Skipping 3rd-party code - usually resides in subfolder "lib"
    if "lib" in dirnames:
        dirnames.remove("lib")
    # Skipping hidden folders
    for dirname in dirnames.copy():
        if dirname.startswith("."):
            dirnames.remove(dirname)