def import_attribute(self, path):
        module = '.'.join(path.split('.')[:-1])
        function = path.split('.')[-1]

        module = importlib.import_module(module)
        return getattr(module, function)
Import an attribute from a module.
dataset/ETHPy150Open flashingpumpkin/django-socialregistration/socialregistration/mixins.py/CommonMixin.import_attribute