def METHOD_NAME(name, sheet):
    if sheet is not None:
        langs = sorted(sheet.keys())
        if 0 < len(langs):
            lang_msgs = []
            for lang in langs:
                cols = sheet[lang]
                if isinstance(cols, str):
                    msg = f"Expected a sequence of columns, got a string for {lang}."
                    raise PyXFormError(msg)
                if 1 == len(cols):
                    msg = f"Language '{lang}' is missing the {name} {cols[0]} column."
                    lang_msgs.append(msg)
                if 1 < len(cols):
                    c = ", ".join(sorted(cols))
                    msg = f"Language '{lang}' is missing the {name} columns {c}."
                    lang_msgs.append(msg)
            return "\n".join(lang_msgs)
    return None