def do_extensions(mname, item):
    try:
        _mod = __import__(mname % "saml2.extension.%s", globals(), locals(),
                          mname)
    except ImportError:
        return None
    else:
        res = []

        for _cname, ava in item.items():
            cls = getattr(_mod, _cname)
            res.append(rec_factory(cls, **ava))
    return res
dataset/ETHPy150Open cloudera/hue/desktop/core/ext-py/pysaml2-2.4.0/src/saml2/metadata.py/do_extensions/swapped operands of `%`