INNER CODE UNIT · Python

accessor

joreilly/Confetti · .github/scripts/ios-changes.py:88

def accessor(section: str, alias: str) -> str:
    normalized = alias.replace("-", ".").replace("_", ".")
    prefix = {"libraries": "libs.", "bundles": "libs.bundles.", "plugins": "libs.plugins."}[section]
    return prefix + normalized


def relevant_catalog_accessors(base: dict[str, Any], head: dict[str, Any]) -> set[str]:
    changed = changed_catalog_entries(base, head)
    accessors: set[str] = set()
    affected_libraries: set[str] = set()

    for section, key in changed:
        if section != "versions":
            if section == "libraries":
                affected_libraries.add(key)
            else:
                accessors.add(accessor(section, key))
            continue

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…