def is_compatible_loader(Loader, context):
    """Return whether a loader is compatible with a context.

    This checks the version's families and the representation for the given
    Loader.

    Returns:
        bool

    """
    if context["subset"]["schema"] == "avalon-core:subset-3.0":
        families = context["subset"]["data"]["families"]
    else:
        families = context["version"]["data"].get("families", [])

    representation = context["representation"]
    has_family = ("*" in Loader.families or
                  any(family in Loader.families for family in families))
    has_representation = ("*" in Loader.representations or
                          representation["name"] in Loader.representations)
    return has_family and has_representation