def get_versio_versioning_scheme(full_class_path):
    """Return a class based on it's full path"""
    module_path = '.'.join(full_class_path.split('.')[0:-1])
    class_name = full_class_path.split('.')[-1]
    try:
        module = importlib.import_module(module_path)
    except ImportError:
        raise RuntimeError('Invalid specified Versio schema {}'.format(full_class_path))

    try:
        return getattr(module, class_name)
    except AttributeError:
        raise RuntimeError(
            'Could not find Versio schema class {!r} inside {!r} module.'.format(
                class_name, module_path))
def get_versio_versioning_scheme ( full_class_path ) : module_path = '.' . join ( full_class_path . split ( '.' ) [ 0 : - 1 ] ) class_name = full_class_path . split ( '.' ) [ - 1 ] try : module = importlib . import_module ( module_path ) except ImportError : raise RuntimeError ( 'Invalid specified Versio schema {}' . format ( full_class_path ) ) try : return getattr ( module , class_name ) except AttributeError : raise RuntimeError ( 'Could not find Versio schema class {!r} inside {!r} module.' . format ( class_name , module_path ) )
Return a class based on it's full path