def clean_alias_tuple_for_comparing(ns, nid):
    alias_tuple = normalize_alias_tuple(ns, nid)
    if not alias_tuple:
        return None
    try:
        (ns, nid) = alias_tuple
        cleaned_alias = (ns.lower(), nid.lower())
    except __HOLE__:
        logger.debug(u"problem cleaning {ns} {nid}".format(
            ns=ns, nid=nid))
        cleaned_alias = (ns, nid)
    return cleaned_alias
dataset/ETHPy150Open Impactstory/total-impact-webapp/totalimpactwebapp/aliases.py/clean_alias_tuple_for_comparing